• Resolved mmpresti

    (@mmpresti)


    I’m trying to set up wordpress with a new static ip address. The only problem is it looks like wp-cron keeps calling up my old ip address. When I set WP_DEBUG to true, I get a few messages on the white screen:

    Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /usr/share/wordpress/wp-includes/wp-db.php on line 1142

    Warning: fopen(http://(my old ip)/(my blog)/wordpress/wp-cron.php?doing_wp_cron=1406432128.5720839500427246093750): failed to open stream: Connection timed out in /usr/share/wordpress/wp-includes/class-http.php on line 955

    Could someone please tell me what this last error means? Where am I to find the call to fopen? and how am I to change the old ip to the new one?

Viewing 8 replies - 1 through 8 (of 8 total)
  • What jobs are you getting wp-cron to do, do they need to be re-configured ?

    Do a database backup, find where your old ip is being used.

    Thread Starter mmpresti

    (@mmpresti)

    I am not sure wp-cron is responsible. So far, after re-installing mysql the problem is still there, so it is not a database connection problem. Here is an outline of the problem:

    1) I try to connect to my wordpress blog http://(new ip)/(blog name)/wordpress

    2) White screen, no debug messages with debugging on.

    3) I try to login to my wordpress blog http://(new ip)/(blog name)/wordpress/wp-login.php

    4) The status of the browser goes from “transferring data from (new ip)…” to “Connecting to (old ip)”! I get to a login screen, but I can’t do anything from there because the links all point to the url that has reverted back to my old ip.

    Thread Starter mmpresti

    (@mmpresti)

    Wp-cron is definitely not the problem. I set ALTERNATE_WP_CRON to true in wp-config.php, and I’m no longer getting this error message, but I’m still left with the same problem.

    Now I’m investigating the first error about replacing mysql-connect() with mysqli or PDO. In doing a little research this seems complicated.

    Thread Starter mmpresti

    (@mmpresti)

    This last error message does not really apply to this problem because the only place it is used in wp-db.php is in a condition for “if (DEBUG)”. So this error is only relevant to debugging. Altogether then this problem shows no debugging errors.

    Thread Starter mmpresti

    (@mmpresti)

    Ok, I figured it out. I was backing up my old wordpress mysql table using mysqldump, and wordpress logs your url at the bottom of each post, with the old ip address. When I restored the old table after reinstalling mysql, the old ip was appended to the posts and many other places in the backup file. This was keeping me from reinstalling wordpress.

    Is there anyway around having to reinstall wordpress every time my ip changes?

    Yes there is, aspects of each of these articles are relevant to you:

    http://codex.wordpress.org/Changing_The_Site_URL

    http://codex.wordpress.org/Moving_WordPress

    After I move a site I run a tool.

    https://interconnectit.com/products/search-and-replace-for-wordpress-databases/

    Put the extracted zip files in a folder called dbsr in your sites main folder.
    then go to the following url:
    http://www/<yoursite>/dbsr

    This will take you the tools page where you can click on dry run to see the results but not change anything.

    Thread Starter mmpresti

    (@mmpresti)

    thanks, very helpful : )

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘Installing WordPress with new ip address’ is closed to new replies.