Nov 8, 2009

How Do I Mirror A Website?

free web hosting
Open Discussion > MODERATED AREA > Computers > Programming Languages > HTML, XML etc..

How Do I Mirror A Website?

kvarnerexpress
After the last batch of hurricanes we lost 5 days of traffic due to power outages in S. Florida.

What I really want to do is redirect a visitor to a copy of the website if the original site takes more than a set amount of time.
If heavy traffic causes the original site to take more than 10 seconds to load I want the visitor automatically redirected to a copy on a different server.

Can this be done somehow? I'm thinking the requests might have to go through a first server that times the two other servers and decides which is the best route.

Any ideas?
Thanks,

Comment/Reply (w/o sign-up)

BuffaloHELP
How about inserting a redirect script in 403 error page? You can insert a 10 second delay (less than 10 or zero delay) in your customized 403 error page that will redirect the traffic to your set URL.

Tools involved:
editing your own 403 HTML file
editing your .htaccess file

Notice from BuffaloHELP:
Nope never mind. I just realized the error in my logic. And it's not what you requested.

Comment/Reply (w/o sign-up)

no9t9
yes, you can do that. you will have to setup your domain to point to a server that is outside of florida and then have that page run a script that pings your "mirror" servers and then redirect to the mirror with the quickest ping time.

if the server is down, you will not get a response. But you might have to set the timeout to something like 500ms because you dont want people to be waiting for your site to load.

I did a quick google on php ping and found a script from hotscripts that can ping a server to tell if it is online or offline.

http://www.hotscripts.com/Detailed/45590.html

Once you know if it is online or offline, then all you have to do is redirect to the one with lowest ping that is online.

Comment/Reply (w/o sign-up)

switch
the problem with all this is that you have to go through a server before it checks if the other servers are down, i.e. if the redirecting server crashes, then you're no better off than before!

I thought the idea of Buffalohelp's 403 error redirect script was brilliant... but then i read the comment that says it doesn't work (if anyone is wondering why, it's because for a 403 error page to get to the user, the server needs to generate a 403 page. If the server's down, this won't occur.)

I think the only way to do it would be to involve the DNS (Domain Names Server). However, I don't think you can do it this way.

I guess the easiest solution is to put on your main website a link to the mirror so people knew the link to the mirror if the main site was down.

I'm not sure if this would work, but it's an idea:
When the web page can't be found, the browser checks the Temporary Internet Files to see if it can find a file there (I think. You'd want to check this). Maybe you could make it so that each page on your site automatically checks if your site is up... then, when the Temporary Internet Files version was loaded, it would check to see if your site was up, realise it isn't, and redirect accordingly. This would only work if the user had previously visited your site, though.

hope I've helped smile.gif

cheers.

 

 

 


Comment/Reply (w/o sign-up)

DeveloperX
U may create a mirror of your website at freeservers.com.
There U must create a free subdomain.
After it goto your account and click "Manage site".
There U can see button "Upload from other site"... but they give free only 20 Mb space....

Comment/Reply (w/o sign-up)

(G)Dave A
This can be done if you can spend the time & money to design and implement it
How Do I Mirror A Website?

Replying to DeveloperX

I thought the questioner was looking for a solution that involves

A) DNS entries that can be changed in the event of a disaster like a hurricane so a request to the site will be sent to an alternate host. I believe there may be a way to set up DNS to point to a list of potential server sites, but this is far from my areas of expertise.

B) some method to allow the alternate sites to stay synchronized with the 'main' site. This could be as simple as manually or by schedule (daily, hourly, minute) dumping all the content from site A to standby copy sites at different locations. This approach (the automatic one) can get complex and difficult to manage. It takes a lot of careful planning and decision making about what is important, how important it is ($$$), and what it will cost to implement.

A fully 'mirrored' disaster-ready site would actually consist of multiple sites doing the user interactions and sharing a set of databases or files located at several sites. No single site is 'the site'; under "normal" use and under disaster conditions, the "site" would continue to operate pretty much the same way as long as there were at least one 'presentation' site and one site with the db and/or files that are available. Modern DBs have "real time" replication mechansisms that can help with the problem, but writable files are a different issue --- you site should probably try to avoid the use of any writable files and do all writing into the db.


There is no generally useful ready made out-of-the box easy solution that I am aware of. If you are willing to live with a somewhat degraded site ... Say with a warning that there was a disaster and that this is the standby site and it may not be entirely up to date, then this is probably pretty do-able with some simply site copying and dns manipulation.



-reply by Dave A

Comment/Reply (w/o sign-up)

k_nitin_r
QUOTE (kvarnerexpress @ Dec 7 2005, 09:09 PM) *
After the last batch of hurricanes we lost 5 days of traffic due to power outages in S. Florida.

What I really want to do is redirect a visitor to a copy of the website if the original site takes more than a set amount of time.
If heavy traffic causes the original site to take more than 10 seconds to load I want the visitor automatically redirected to a copy on a different server.

Can this be done somehow? I'm thinking the requests might have to go through a first server that times the two other servers and decides which is the best route.

Any ideas?
Thanks,



Hi!

I'm guessing you want to install a script on your website that re-directs the user to another server. The problem that is apparent is that if your web server is down, the user would not be able to get to the script.

However, you can have a small amount of space on a managed hosting provider and host stuff like videos and other bandwidth intensive stuff on your own web server. You can then have a script on the managed provider that checks for connectivity to your web server; if it is inaccessible then it can redirect the user to another web server. To mirror your data, you could have a cron job to run a shell script or something similar that can ZIP your files, while a shell script on the other server can download them via FTP and copy them to it's own document folder. For MySQL, you might be able to setup replication using a 3rd party solution or, alternatively, you could write your own script to synchronize the data.

Regards,
Nitin

Comment/Reply (w/o sign-up)



Got an Opinion! Express your Views! (no registration):-
Add your Reply/ Opinion/ Views/ Comments/ Suggestion/ Questions/ Queries etc.
Posts with decent grammar & English will be accepted and please refrain from profanities.
For asking a Question, We recommend you to sign-up (for free) so that you can track the topic easily.

Nature of your Post*: Opinion/ Reply/ Comments
Question/Query
Feedback to us.
       
Name   Email
Title/Question*

This textarea will convert to Rich-Text automatically (IE, Firefox, Chrome)

Similar Topics

Keywords : Mirror Website

  1. Tips on creating a good website! - (13)
    1) Navigation: Keep it simple (KISS), and make sure it's consistent from page to page. No matter
    where you place your menu bar -- either at the top or down the side -- always include a small text
    menu at the bottom of every page. If you're one of those people easily impressed with Flash,
    don't design your navigation with it. There are still some people who don't have or want the
    plug-in, so they won't be able to navigate your site. Besides, search engine spiders can't
    read it, so won't be able to spider the individual pages of your site if the...
  2. Build A Website - (18)
  3. Html Templates - HTML Templates for website (4)
    Where do i get free HTML Templates to use in look and feel of website? Any link will be
    helpfull....I know there are some free templates available but it is hard to find even by
    gooooogling it. Please, share if you have any. Thank You....
  4. Website Drop Shadow Effect Help - (7)
    Well I am in a need of help, I want to add this cool drop shadow effect to a website I am building,
    but unfortunately for me I can't seem to get it right. I want to apply this drop shadow effect
    to this website The first person to effectively apply this drop shadow to this website
    will get a 50 credit prize All the files are provided, you have to download the OSWD file to get
    the images and style effect, there is no rush but if you can get it done right away I be much
    appreciated....
  5. Website Problems Please Help - Unwanted gap between the welcome bar and flash. (6)
    I just set up this website, none of the links are in working condition yet. This is mainly because
    im trying to get rid of this anoyying gab in between my flash object and my welcome bar (its the
    small dark grey/brownish gap). Does anyone know exactly how to fix this without messing anything
    else up vis changing the code or possibly even the size of the flash? Thanks. Here is the website:
    http://www.childrenofconan.trap17.com/ Moved to html section in anticipation of that being the
    correct Forum ...
  6. Making This Website Automatically Scale For Browsers - (1)
    Hi I am trying to scale the code below so It can be used for a furniture business website
    successfully, heres the code: "http://www.w3.org/TR/html4/loose.dtd"> Home
    Lorem ipsum quaeque
    eripuit probatus id usu, nec ea dos epic uri verterem, quando tempr et mei. Eam equidem erroribus
    an, id nam illum perse- cuti read more 12/20/2007 Lorem ipsum
    quaeque eripuit probatus id usu, nec ea dos epicuri verterem, quando tempr ...
  7. Help With Website Layout Correction For All Browsers - Page gets larger on Firefox 2 (4)
    If you go to my site at http://boozkerstweaks.trap17.com and you look at the home page everything
    is fine on all browsers. Problems start to arise very soon however. Here is my list of problems and
    i was wondering if someone could help with just whats wrong. I have done a HTML validator and found
    only 3 errors and all these problems still occured. You might find more now though because i am
    screwing around with the code. Here is the list of browsers and errors: Netscape 8.1: After you
    click on the pulldown menu and click the only tweak avaible at the moment the pag...
  8. Background Image Picture On A Website - how do u make a pic a backround?? (3)
    ?email me if u know! Trap17 forum asks you to post contributes with substance. ...
  9. How To Make Cms For My Dynamic Website? - A Content Management System (3)
    It is a pain trying to have to write new code everytime you want to change something on my website.
    I know there is an easier way to update content. I read about COntent Management systems which
    apparently use XML. When I would enter the administartion area there woudl be dynamic fileds in
    which I could edit the data and when I click submit it would change. The thing is that I know how
    to add these forms to a page but I dont know how to create an adminstration area. I use php and one
    of my friends said to use XML. I have a book but it is taking a long time to read....
  10. Making A Refresh Link On Your Website. - refresh local webpage (16)
    /smile.gif' border='0' style='vertical-align:middle' alt='smile.gif' /> post it on ur website
    CODE refresh It can refresh local webpage. U can add it at ur forum so that each topic u
    are reading can be refresh easily. If ur website return to homepage after pressing I.E. refresh
    button, then u must need this coding. /cool.gif' border='0' style='vertical-align:middle'
    alt='cool.gif' /> Beacus visitors only want to refresh local webpage but not go back to homepage.
    /ohmy.gif' border='0' style='vertical-align:middle' alt='ohmy.gif' /> * same co...
  11. Website Deployment Problems - (3)
    Hello, I have developed a website that is specific to IE. The website looks great on my local
    machine. I then move it to my production environment. For some reason, the website now looks
    different when I view it from the production server. The strange thing is... I am using the same
    browser. I always believed that HTML was downloaded to the client and then it was up to the browser
    to render it. Considering I am viewing the webpage using the same browser from my machine... I
    should have received the same thing. Which lead me to believe that I didn't upload it prop...
  12. Website Copy Protection - (15)
    Hey people, thanks for the help in advance. I notice that my competition refuses to put the time
    into their websites that I do and have been stealing my pages. Copying my web text is one thing, but
    I notice often times my entire page is stolen, from what looks like a 'Save Page As' deal.
    What can I do to protect myself from this web theft, or at least to make it harder. I dont use any
    java, I use straight CSS on all my pages. Thanks. kvarnerexpress...
  13. Ftp Website - (0)
    hi guys, i am creating an FTP site which will have alot of folders on it each with subfolders and
    so on. the folders will be created every day on a machine and then sent to the site. i wanted to
    know if i can use a custom made DOS program created using the C language to upload the files and
    create the folders on the site or do i have to upload the folders invidually. i am a complete
    novice on FTP sites but have created a client for FTP transfers already, a pointer to a library of
    functions or general help would be gratefully appreciated. i am using VC++ 6 and windo...
  14. I Finally Found A Simple Way To Do A Blendtrans - - want some cool effect for your website? (1)
    ok, this code isn't supported by some browsers, like Firefox. But it still works for the
    OnMouseOver. This code basically fades one images into another one. Really cool effect
    /biggrin.gif' border='0' style='vertical-align:middle' alt='biggrin.gif' /> . First thing: build or
    find 6 images, 3 pair. your going to want to build buttons that are close in relation, so they fade
    properly. Name the images as so: image1_on.gif , image1_off.gif image2_on.gif , image2_off.gif
    image3_on.gif , image3_off.gif now put these in a folder called: "images" inside your original...
  15. Optimizing Website? - (10)
    I am sure there is the way to optimize website, so that is looks exactly how you want in every
    browser. I don't know it, so can somebody help me with that?...
  16. Website Security - encryption/html function disabling etc. (2)
    Hey Guys, Searched for posts re: webpage security (keeping slimeB*lls from "borrowing" your content)
    on the forums & came up blank. So thought I'd start a string here. OK, so does anyone have any
    info to contribute? Has anyone used html encryption programs? Does this create problems with
    browsers "reading" the page content or other functionality problems? What about webpage/html
    modifications/"updates" after the page has been encrypted? How good is the encryption OR how easy is
    it to hack/crack etc. ??? Anybody? Cheers! PS-Any strings/links in the forums I've mis...
  17. Show The Last Update Time Automatically - very helpful to your website (5)
    After we ourselves upload webpage, will often bring in constant renewal in and add the new content ,
    and how could let net friend to browse through webpage know working hard getting newer one's
    own? Usually we will list the last date that this webpage will be upgraded in one mao of the
    webpage, but if this job is come to do by hand, troublesome and easy to forget. How to solve this
    problem? Having seen this small skill, you will say , it was so simple originally definitely. All
    right, now we do it. The source code pastes the frame : document.write("This last u...
  18. going to far when designing a website - all opinions for this one (3)
    how far is going to far to make sure to get those 90 billion hits a day on your website. if your
    creative with your scripting and it makes the user looking at your page happy ok that fine and
    dandy. but if you add all thos high speed tricks to your website like making text flash 6000
    different pop up adds per click QUOTE then you should be drag outside and shot for wasting web
    space /tongue.gif" style="vertical-align:middle" emoid=":P" border="0" alt="tongue.gif" />.
    but for me if its a useful trick like making text pop up if a person wants to know more th...



Looking for mirror, website

Searching Video's for mirror, website
See Also,
advertisement


How Do I Mirror A Website?

Affordable Web Hosting, Low cost Web Hosting - ComputingHost.com