|
| Author |
Message |
~HG~
Joined: 25 Sep 2005
Posts: 423
Location: Australia
|
Posted: 12/18/2005, 2:31 pm Post subject: Uninstalling MySql |
|
|
As you know with a lot of mods/hacks you have to run a MySql query for them to work. This if of course provided in the hack itself either as the raw code or as a .php file that runs in your browser.
All great except for one thing.
If you decide you no longer want the mod, or it does not do anything for you, the authors do not include an uninstall instruction for MySql.
It should be mandatory with all mods to include uninstall instructions as well as the install.
Now I have remove numerous mods over time that have not had any benefit to my forum but in most cases the changes made in the MySql are still in place, particularly where the changes affect php_board_config values.
Leaving these changes in place do not stop the veiwing using of the forum of course but I do believe they slow down the pages. Someone may be able to confirm this one way or another for me please.
My question is twofold.
Firstly, is there anyone that knows of a simple way of writing an uninstall code for MySql and secondly, do you agree that uninstall instructions should be included with every mod/hack that is validated for release ??? _________________ ~HG~
|| Click here to view all my phpBB Communities || |
|
| Back to top |
|
 |
chrispian
Joined: 31 Aug 2005
Posts: 132
|
Posted: 12/18/2005, 3:22 pm Post subject: |
|
|
That topic is very broad. There is no "magic bullet" to solve this because one mod might alter a few existing tables (YUCK!) and some may install new ones and yet others may do both or something entirely different. You can't really know. I've made a pretty concerted effort to avoid mods that require changes to the core tables that come with my forum software. If they add their own, fine, because if I uninstall I can just delete those tables.
There isn't an easy solution here though and the best way to go forward is to be proactive and advocate that any mods come with clear uninstall instructions. _________________ Chrispian H. Burks
451 Press |
|
| Back to top |
|
 |
Thoul
Joined: 14 Sep 2005
Posts: 169
|
Posted: 12/18/2005, 3:58 pm Post subject: |
|
|
I've given some thought to creating a tool, like the db_update generator for phpBB, that would create an uninstaller.php file when given the SQL queries that come with a mod. Haven't had time to make it more than an idle thought, though.
Some queries are simple to reverse, but some that make massive changes are very hard to uninstall. _________________ Phantasy Star: The Fringes of Algo | phpBB Smith |
|
| Back to top |
|
 |
Ex0dus
Joined: 26 Sep 2005
Posts: 235
Location: Zarasu, Lithuania
|
Posted: 12/19/2005, 9:59 am Post subject: |
|
|
Well ill give you a basic two fold answer to your questions >_<:
1. Leaving the tables/columns in the database without using them does not cause a significant slowdown. So long as the piece in question is not called in your code and your forum is not super huge (im talking 20k + users and 200k + posts), then it wont make much of a difference. Once you uninstall the mod in question, the database no longer fills in values for that part anymore (in the chance that more users register in the case of a users table mod, or more forums are made in the case of the forums table) so even then database growth caused by leaving a unactive table in there is minimal. Yes it looks kind of sloppy, but it isnt dangerous. Then again, who else ther than you should be looking at your database anyway? =p
2. Mandating that uninstallers be included is a nice thought, but impractical. What kind of message are you sending to your users if you start packaging uninstallers with your product? Unless its something huge like categories hierarchy or attach_mod making an uninstaller sends the wrong message and is ususally not a good use of time (since more people end up keeping the mods and adding more rather than removing).
Making and giving instructions on how to add the mod is a mod makers job, not catering to those who dont make file backups (in the case of code changes) especially when every install file ive ever seen (and trust me, ive seen alot) say to back up all files related to the mod.
-Ex0dus |
|
| Back to top |
|
 |
NullSmurf
Joined: 04 Oct 2005
Posts: 5
Location: Aurora (Denver) Colorado USA
|
Posted: 1/4/2006, 11:54 pm Post subject: |
|
|
I'm a serious doofus in php, but I'm well grounded in SQL - my day job helps with that. In my day job, I also deal with tables with millions of lines. An extra column or two, or even extra tables left over from an unused mod doesn't seem to be much of a draw, even on larger boards.
For myself, I'm able to read the install files that ran the SQL statements that modified my database and undo it.
As for mandatory uninstalls, ain't going to happen. You'll just have to get your money back on the MOD.  _________________ Smurf
World class scale ship builder
Amateur Community Admin
SSMA |
|
| Back to top |
|
 |
Dash
Joined: 03 Jan 2006
Posts: 26
Location: Montreal, Canada
|
Posted: 1/5/2006, 2:41 am Post subject: |
|
|
Unused MySQL Columns won't really change anything, consider them as an empty highway, if nobody is using it, there won't be any traffic jams. _________________ DTG Live! an online post-apocalyptic MMORPG in an old-school 8-bit style, build your own house, fight monsters and players! |
|
| Back to top |
|
 |
LadyMinion
Joined: 05 Jan 2006
Posts: 14
Location: UK
|
Posted: 1/5/2006, 11:44 pm Post subject: |
|
|
| Ex0dus wrote: |
hat kind of message are you sending to your users if you start packaging uninstallers with your product? Unless its something huge like categories hierarchy or attach_mod making an uninstaller sends the wrong message and is ususally not a good use of time |
I have to disgree with this statement. When you purchase a piece of software you expect an uninstaller to come with it, do you not? Isn't it considered extremely unprofessional for a company to not provide a way to remove their software? We certainly don't believe software companies are sending the "wrong message" by letting us have the freedom to do this. In fact, we become very angry if we install a product and find no way to remove it later.
So why should forum hacks be any different?
I personally am very grateful to any mod author who takes the time to write a SQL uninstall script to go with their mod. _________________ PF.Net ~ The home of Phantom Phans
PF.Net ~ The home of Geriks Phans |
|
| Back to top |
|
 |
Dash
Joined: 03 Jan 2006
Posts: 26
Location: Montreal, Canada
|
Posted: 1/6/2006, 1:55 am Post subject: |
|
|
Because most forum hacks are freeware? I know, I know, you'll probably say that it doesn't mean it's freeware that it has to be bad, but get this, I have made dozens of personal mods that a lot of people could find very handy, but after developping these mods and working on so many files, I wonder if it's actually worth my time to try to compile all my changes into one big chunk for people to use. Already putting a mod together is work enough I guess... People share their work, they don't do it for the sake of doing it.
AFAIK Most Easymod compliant mods can be easily uninstalled. _________________ DTG Live! an online post-apocalyptic MMORPG in an old-school 8-bit style, build your own house, fight monsters and players! |
|
| Back to top |
|
 |
Patrick
Administrator
Joined: 28 Aug 2005
Posts: 2212
Location: Harbinger, NC, U.S.A.
|
|
| Back to top |
|
 |
LadyMinion
Joined: 05 Jan 2006
Posts: 14
Location: UK
|
Posted: 1/6/2006, 12:58 pm Post subject: |
|
|
| Dash wrote: |
Because most forum hacks are freeware? I know, I know, you'll probably say that it doesn't mean it's freeware that it has to be bad, but get this, I have made dozens of personal mods that a lot of people could find very handy, but after developping these mods and working on so many files, I wonder if it's actually worth my time to try to compile all my changes into one big chunk for people to use. Already putting a mod together is work enough I guess... People share their work, they don't do it for the sake of doing it.
AFAIK Most Easymod compliant mods can be easily uninstalled. |
That's fine. My point was that coders who do take the time to make an uninstaller shouldn't be made to feel that there is something wrong with their product.
I certainly don't expect it, but I do appreciate it when it's done.  _________________ PF.Net ~ The home of Phantom Phans
PF.Net ~ The home of Geriks Phans |
|
| Back to top |
|
 |
|