XFileSharing Pro - MFHS 1.5 to XFS 2

Message
Author
Guizmo
Posts: 19
Joined: May 27, 2012 3:41 am

MFHS 1.5 to XFS 2

#1 Postby Guizmo » Jul 23, 2012 7:50 pm

Hi guys,

I'm planing to migrate from a site using MFHS to the XFS script.

There is any way to do it for free ? Even if i've to do it manually..

Thanks :)

hostlife
Posts: 192
Joined: Aug 13, 2011 12:34 pm

#2 Postby hostlife » Jul 23, 2012 11:15 pm

No, there is no converter available for this.

Guizmo
Posts: 19
Joined: May 27, 2012 3:41 am

#3 Postby Guizmo » Jul 23, 2012 11:55 pm

Thanks for your reply.. I'll try to do it manually pfiou !

Guizmo
Posts: 19
Joined: May 27, 2012 3:41 am

#4 Postby Guizmo » Sep 13, 2012 12:46 pm

Bump to tell to people in my case, it's possible to migrate manually in few steps from MFHS to XFS. I had ~1400 files on MFHS that I've imported into XFS with redirecting old links on new links.

To migrate :

AT FIRST ! This mini tutorial will works perfectly if you was using url rewriting like "www.oldsite.com/en/files/442/blabla.html"

1 - Dump from your sql in a file : id, file, name, downloads from the table FILES

2 - Move files from the old folder /files into the new folder /cgi-bin/ImportedFiles

3 - Use the Import files function from you admin panel on your server list

4 - Dump file_name, file_code from the table Files of the xfs db

5- Find a way to rename all files with its real filename (from 3d42a213_1.rar to The_Real_Name.rar) thanks to the 2 dumps
For this step, I used a C# script i made to find the real name of a given file and to generate the correct update set sql..
I can share it for free if asked but it is customised for me, I can recode it..

6- Find a way to execute the update set sql that the script generated (something like : UPDATE Files SET file_name='The_Real_Name.rar' WHERE file_name='3d42a213_1.rar') (ssh, phpmyadmin etc..)

You can add the number of downloads to the request if you want.

7- All files are now imported with the correct name. To redirect all links with new links.
Find again a way to generate for all files on your dumps, 2 lines like :

RedirectMatch permanent /file/1/(.*) /qnluph835izw
Redirect permanent /file/1 /qnluph835izw

Those lines redirect the old link www.oldsite.ws/en/files/1/toto.html to www.oldsite.ws/qnluph835izw

Add, at the top those lines :
RedirectMatch permanent /(.*)/files/(.*)/(.*)$ /file/$2
RedirectMatch permanent /(.*)/files/(.*)$ /file/$2

Save all generated lines into your .htaccess root forum of your main server and all will works perfectly !

Sorry it's a very light tutorial.. Just to give you ways to do it yourself ! ;)

admin
Site Admin
Posts: 1839
Joined: Mar 22, 2006 12:32 pm

#5 Postby admin » Sep 13, 2012 12:57 pm

Great job. If you dont mind, can we make your tutorial it sticky?

Guizmo
Posts: 19
Joined: May 27, 2012 3:41 am

#6 Postby Guizmo » Sep 13, 2012 1:50 pm

Of course you can, hope it will help !