Re: Suppressing DNS lookups when using wget, forcing specific IP address

2007-06-19 Thread Kelly Jones

This looked promising, but I couldn't quite get it to work even w/o --mirror:

wget --header=Host: www.yahoo.com http://216.109.112.135/

(yes, 216.109.112.135 is one of Yahoo's IP addresses). The result is a
sorry, page could not be found error. A network sniffer shows I sent this:

GET / HTTP/1.0
User-Agent: Wget/1.8.2
Host: 216.109.112.135
Accept: */*
Connection: Keep-Alive
Host: www.yahoo.com

In other words, I sent 2 Host: headers, and yahoo.com used the first
one (the server I'm actually interested in does the same thing).

But this seems really close to what I want. Any suggestions/thoughts anyone?

On 6/18/07, Tony Lewis [EMAIL PROTECTED] wrote:

Try: wget http://ip.of.new.sitename --header=Host: sitename.com --mirror

For example: wget http://66.233.187.99 --header=Host: google.com --mirror

Tony
-Original Message-
From: Kelly Jones [mailto:[EMAIL PROTECTED]
Sent: Sunday, June 17, 2007 6:10 PM
To: wget@sunsite.dk
Subject: Suppressing DNS lookups when using wget, forcing specific IP
address

I'm moving a site from one server to another, and want to use wget
-m combined w/ diff -auwr to help make sure the site looks the same
on both servers.

My problem: wget -m sitename.com always downloads the site at its
*current* IP address. Can I tell wget: download sitename.com, but
pretend the IP address of sitename.com is ip.address.of.new.server
instead of ip.address.of.old.server. In other words, suppress the DNS
lookup for sitename.com and force it to use a given IP address.

I've considered kludges like using old.sitename.com vs
new.sitename.com, editing /etc/hosts, using a proxy server, etc,
but I'm wondering if there's a clean solution here?

--
We're just a Bunch Of Regular Guys, a collective group that's trying
to understand and assimilate technology. We feel that resistance to
new ideas and technology is unwise and ultimately futile.


RE: Suppressing DNS lookups when using wget, forcing specific IP address

2007-06-18 Thread Tony Lewis
Try: wget http://ip.of.new.sitename --header=Host: sitename.com --mirror

For example: wget http://66.233.187.99 --header=Host: google.com --mirror

Tony
-Original Message-
From: Kelly Jones [mailto:[EMAIL PROTECTED] 
Sent: Sunday, June 17, 2007 6:10 PM
To: wget@sunsite.dk
Subject: Suppressing DNS lookups when using wget, forcing specific IP
address

I'm moving a site from one server to another, and want to use wget
-m combined w/ diff -auwr to help make sure the site looks the same
on both servers.

My problem: wget -m sitename.com always downloads the site at its
*current* IP address. Can I tell wget: download sitename.com, but
pretend the IP address of sitename.com is ip.address.of.new.server
instead of ip.address.of.old.server. In other words, suppress the DNS
lookup for sitename.com and force it to use a given IP address.

I've considered kludges like using old.sitename.com vs
new.sitename.com, editing /etc/hosts, using a proxy server, etc,
but I'm wondering if there's a clean solution here?

-- 
We're just a Bunch Of Regular Guys, a collective group that's trying
to understand and assimilate technology. We feel that resistance to
new ideas and technology is unwise and ultimately futile.



Suppressing DNS lookups when using wget, forcing specific IP address

2007-06-17 Thread Kelly Jones

I'm moving a site from one server to another, and want to use wget
-m combined w/ diff -auwr to help make sure the site looks the same
on both servers.

My problem: wget -m sitename.com always downloads the site at its
*current* IP address. Can I tell wget: download sitename.com, but
pretend the IP address of sitename.com is ip.address.of.new.server
instead of ip.address.of.old.server. In other words, suppress the DNS
lookup for sitename.com and force it to use a given IP address.

I've considered kludges like using old.sitename.com vs
new.sitename.com, editing /etc/hosts, using a proxy server, etc,
but I'm wondering if there's a clean solution here?

--
We're just a Bunch Of Regular Guys, a collective group that's trying
to understand and assimilate technology. We feel that resistance to
new ideas and technology is unwise and ultimately futile.


Re: Suppressing DNS lookups when using wget, forcing specific IP address

2007-06-17 Thread Jim Wright
modify /etc/hosts temporarily on the computer you are running wget
to add a line similar to

1.2.3.4 sitename.com # temporary hack to get new web site

pull the files then remove that line from /etc/hosts.  this assumes
that /etc/hosts has precedence over dns (and yp or whatever) on your
machine; most do.

Jim


On Sun, 17 Jun 2007, Kelly Jones wrote:

 I'm moving a site from one server to another, and want to use wget
 -m combined w/ diff -auwr to help make sure the site looks the same
 on both servers.
 
 My problem: wget -m sitename.com always downloads the site at its
 *current* IP address. Can I tell wget: download sitename.com, but
 pretend the IP address of sitename.com is ip.address.of.new.server
 instead of ip.address.of.old.server. In other words, suppress the DNS
 lookup for sitename.com and force it to use a given IP address.
 
 I've considered kludges like using old.sitename.com vs
 new.sitename.com, editing /etc/hosts, using a proxy server, etc,
 but I'm wondering if there's a clean solution here?
 
 -- 
 We're just a Bunch Of Regular Guys, a collective group that's trying
 to understand and assimilate technology. We feel that resistance to
 new ideas and technology is unwise and ultimately futile.