Host Tornado shell script to fix broken or incorrect paths

Have you ever transferred over your own site or a customers site from another server just to find out that it does not work because the full path has changed? This can commonly happen whenever you transfer over a Joomla, WordPress, Drupal, or any other site but the account now has a username.
So for instance, the path to your public_html folder used to be
but now on the new server it has changed to
or MySQL usernames changed.

Well that can sometimes cause problems with scripts and other installed “stuff” because it still has the setting for /home/myuser/public_html/ but the path has actually changed…well that’s what this script is for.

I created this shell script to provide our techs with an easy to use script can normally resolve these problems. The script will search a specified directory going through each file inside that directory and below it and replace all instances. It will also output what is being done and ask for confirmation.

This was created to have an easy way to update paths, mysql information, etc. If you are familiar with sed, grep, and good with linux this will probably just be redundant for you as what this accomplishes can normally be done in one or two commands, I created this to give our techs a nice interface and output.

This is VERY beta so there may be bugs, if you find any let me know and i will update it.

You can download the file here:


Orlando, FL

Did this post help you?

Give back and rate it for me!

Related Posts