Jump to content
Matt Cohen

Issues moving from IIS localhost machine into Windows Server production

Recommended Posts

Hi everybody, So it turns out PW works on IIS pretty well. Had very little issues in getting it to run and not many issues in getting it setup.... in a localhost environment. 

I've been given a Windows Hyper-V server for the uses of my intranet that I've been building with PW. The only problem is now, I seem to be having issues whenever trying to log in. It doesn't recognize the admin user I created during installation, it simply redirects back to the /login/ page, with no error message. 

Debugging shows the following message on the frontend login screen (not the backend). Localhost does not show this 

Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[22003]: Numeric value out of range: 1264 Out of range value for column 'ip' at row 1' in C:\inetpub\wwwroot\wire\modules\Session\SessionHandlerDB\SessionHandlerDB.module:109 Stack trace: #0 C:\inetpub\wwwroot\wire\modules\Session\SessionHandlerDB\SessionHandlerDB.module(109): PDOStatement->execute() #1 [internal function]: SessionHandlerDB->write('j398has5jatl2lb...', 'Session|a:1:{s:...') #2 [internal function]: session_write_close() #3 {main} thrown inC:\inetpub\wwwroot\wire\modules\Session\SessionHandlerDB\SessionHandlerDB.module on line 109

When moving the dev machine to production, here are the steps I followed:

  • Copied wwwroot from development machine to the production server
  • Exported by site's database using SQL Front and importing on the production server
  • Allowed access on the production server
  • Edited site/config and wire/config to add in the hosts - appname.domainname.co.nz, localhost, 192.1.90.1

Now this is the real kicker:  I can goto http://localhost on the production machine, and get full access and it works fine... However when I try using appname.domainname.co.nz, I keep getting this weird "blank" redirect.

I would really appreciate any help anyone would be able to give me. I have looked all thru the PW forums for something similar around this to no avail.

Share this post


Link to post
Share on other sites

I don't think this is related to processwire but the environments you are using. What processwire version are you using ?

Copied wwwroot from development machine to the production server

This way of moving from dev to production is not recommended as it doesn't check your production environment.

Install a fresh new installation of the same processwire version on the production server and see if this installation

goes error free. This will tell you if processwire matches up with the production server environment.

After that, replace the site folder on the production server with the site folder from the dev server. Empty the database

on the production server and import your database sql file from the dev server. See how that goes.

  • Like 2

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By NooseLadder
      Hi,
       
      I've been out of the game for a number of years (6/7). I have a few projects lined up. I used to use XAMPP on my Windows PC back then. I have a Windows 8.1 laptop atm. Is XAMPP still ok or can you recommend anything better? I used to upload files to server using FileZilla. Thanks.
    • By Peter Knight
      Hi all
      My .htaccess file is correctly redirecting all requests to
      https:// www. That's great until I want to work locally.
      I thought I had seen a blog post by Ryan where there was a new config setting to ignore both of these if working from localhost?
      I can't find it now so wondering if I was imagining 😕
       
       
    • By joeck
      Hi there,
      I'm trying to have a multi-site (multiple databases) setup on a IIS (Microsoft) server.
      I know that IIS is not officially supported by ProcessWire but customer is insisting on IIS.
      I get an 500 Error when trying to access the sub-domain/other processwire site.
      Did somebody do this before or is it not possible at all to have a multi-site setup on IIS?
      Thanks
    • By kongondo
      So, all of a sudden, Chrome is blocking all of my localhost sites, claiming my connection is not Private, blah blah..Here is the full text of what Chrome is telling me.
      I get no option to 'continue to this unsafe site'. 
      It seems I have no option but to install SSL on my local sites. I have seen some articles on how easy it is to do in a Mac but I am on Windows. Anyone has pointers on how I can do this? Alternatively, anyone knows what this Chrome error is about? Bottom line is, unless I change browsers, I am not currently able to develop and test stuff locally. Grr!
      Thanks.
    • By John W.
      Summary: If I have a site sitting on a server called testing.com, then on the server change it to mycompany.com, do I have to modify any settings in ProcessWire?
      After building several processwire for clients, the one question that I haven't had is about moving a processwire site from an old (temporary) domain to a new domain.
      For instance, I typically setup development sites for clients and register a temporary domain (and lock with a password). For instance, thee client can go test.com and get all their content finalized, change wording, add news, swap out photos -- everything to make the site production read.  
      Next, on my hosting account I can have testing.com renamed to theircompany.com - and change the nameservers.
      A simple question here. If I have a hosting company rename the account from testing.com to theircompany.com, change my nameservers whereas going to theircompany.com loads the production site, Is there anything I need to change in the processwire configuration or in the PW database?
      In the past, I've just manually copied the site, and fresh-installed PW, and imported the data. Seems like a lot of hassle.
      I have a second part question about updating the PW core, however, after consideration I'll post it as a new topic.
×
×
  • Create New...