ArticleStorageDB vs. ArticleStorageFS
Moderator: crythias
ArticleStorageDB vs. ArticleStorageFS
Hello forum,
I'd like to have your opinion and experience feedback about attachment storage.
I was used to Ticket::StorageModule = ArticleStorageDB (default option).
But now that our OTRS database is very growing, I am really considering switching to the other option - which should make backups saving easier.
Is it so easy?
How about attachments that are inside the database up to now? Will they be carried off in the file system at the time I switch from ArticleStorageDB to ArticleStorageFS?
Where is the file system located?
It says:
"FS" stores the data on the filesystem; this is faster but the webserver should run under the OTRS user.
What does it mean?
You can switch between the modules even on a system that is already in production without any loss of data.
If I switch, will the new attachments be in a file system, whereas the old attachments will remain in the database?
Best Regards,
HervE
I'd like to have your opinion and experience feedback about attachment storage.
I was used to Ticket::StorageModule = ArticleStorageDB (default option).
But now that our OTRS database is very growing, I am really considering switching to the other option - which should make backups saving easier.
Is it so easy?
How about attachments that are inside the database up to now? Will they be carried off in the file system at the time I switch from ArticleStorageDB to ArticleStorageFS?
Where is the file system located?
It says:
"FS" stores the data on the filesystem; this is faster but the webserver should run under the OTRS user.
What does it mean?
You can switch between the modules even on a system that is already in production without any loss of data.
If I switch, will the new attachments be in a file system, whereas the old attachments will remain in the database?
Best Regards,
HervE
OTRS 3.3.8 - Windows 7 - IIS7 - SQL Server - Firefox 30
-
- Moderator
- Posts: 10170
- Joined: 04 May 2010, 18:38
- Znuny Version: 5.0.x
- Location: SouthWest Florida, USA
- Contact:
Re: ArticleStorageDB vs. ArticleStorageFS
It's probably likely that the attachment source is stored and not modified upon switching locations, which makes sense in a "let's not break things" thought process.
But there is a script bin/otrs.ArticleStorageSwitch.pl that may answer the other part if you wanted to.
It seems pretty simple to use, just tell it where you want to move it from (-s ArticleStorageDB) and where to (-d ArticleStorageFS) and how old (as in closed) you want to start moving data.
Now, I've never used it, etc., so I am just looking at this from a "what should make sense?" and "what would I do?" perspective. Back up before doing anything nasty, test if you can...
But there is a script bin/otrs.ArticleStorageSwitch.pl that may answer the other part if you wanted to.
It seems pretty simple to use, just tell it where you want to move it from (-s ArticleStorageDB) and where to (-d ArticleStorageFS) and how old (as in closed) you want to start moving data.
Now, I've never used it, etc., so I am just looking at this from a "what should make sense?" and "what would I do?" perspective. Back up before doing anything nasty, test if you can...
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Re: ArticleStorageDB vs. ArticleStorageFS
Thanks for your answer - interesting as usual.crythias wrote:there is a script bin/otrs.ArticleStorageSwitch.pl
Now, I've never used it
Has anybody in the forum already tried this script?
Regards,
HervE
OTRS 3.3.8 - Windows 7 - IIS7 - SQL Server - Firefox 30
Re: ArticleStorageDB vs. ArticleStorageFS
lot of times 

"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master
Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
"Testing": ((OTRS Community Edition)) and git Master
Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
Re: ArticleStorageDB vs. ArticleStorageFS
Very good.
What can you say of it?
Is it safe?
Do you recommend to migrate all attachments from DB to file system? (so to keep the entire data homogeneous)
Where is the file system located?
It is said that "FS is faster but the webserver should run under the OTRS user".
What does it mean?
Regards,
HervE
What can you say of it?
Is it safe?
Do you recommend to migrate all attachments from DB to file system? (so to keep the entire data homogeneous)
Where is the file system located?
It is said that "FS is faster but the webserver should run under the OTRS user".
What does it mean?
Regards,
HervE
OTRS 3.3.8 - Windows 7 - IIS7 - SQL Server - Firefox 30
Re: ArticleStorageDB vs. ArticleStorageFS
yeea, it is safe and you should have for your kind of setup all attachments in the same location.
The permissions are for unix users, not for windows.
The location can be set by sysconfig
The permissions are for unix users, not for windows.
The location can be set by sysconfig
"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master
Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
"Testing": ((OTRS Community Edition)) and git Master
Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
Re: ArticleStorageDB vs. ArticleStorageFS
Hi!
I have a problem while I moving attch to FS.
Any idea what should I do?
OTRS version is 3.1.11
I have a problem while I moving attch to FS.
Code: Select all
NOTICE: 10291/30040 (TicketID:10374)
ERROR: OTRS-otrs.ArticleStorageSwitch.pl-10 Perl: 5.10.1 OS: linux Time: Wed Nov 28 15:13:11 2012
Message: Not all files are moved! (TicketID:10374/ArticleID:28962)!
Traceback (26994):
Module: Kernel::System::Ticket::TicketArticleStorageSwitch (v1.549.2.9) Line: 7609
Module: bin/otrs.ArticleStorageSwitch.pl (v1.16) Line: 164
Any idea what should I do?
OTRS version is 3.1.11
-
- Moderator
- Posts: 10170
- Joined: 04 May 2010, 18:38
- Znuny Version: 5.0.x
- Location: SouthWest Florida, USA
- Contact:
Re: ArticleStorageDB vs. ArticleStorageFS
Yes ... look at that ticket/article and check whether it's relevant to you.palcic wrote:Any idea what should I do?
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Re: ArticleStorageDB vs. ArticleStorageFS
Ok, so is it possible to skip that ticket or I must to delete it from DB?
And if is delete the only option, which data I should delete?
And if is delete the only option, which data I should delete?
-
- Moderator
- Posts: 10170
- Joined: 04 May 2010, 18:38
- Znuny Version: 5.0.x
- Location: SouthWest Florida, USA
- Contact:
Re: ArticleStorageDB vs. ArticleStorageFS
I don't know if this *stopped* or skipped for you. I would hope it skipped this. Basically, I can't tell you the answer. You should look at tickets before and after this and see if there are attachments accessible. If so, don't worry about it unless you need *this* attachment. If the attachments around this ticket are inaccessible, you may have other issues, but only you would be able to determine the effects simply by observing the ticket attachments. If they work... don't worry about it. If they don't work, well, you may need additional professional assistance.palcic wrote:Ok, so is it possible to skip that ticket or I must to delete it from DB?
And if is delete the only option, which data I should delete?
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Re: ArticleStorageDB vs. ArticleStorageFS
One ticket is not problematical, but what about other tickets after this error? Is process stopped or it's go further till the last ticket? My guess, it's stopped. So, how to move other 20k tickets after stop?
-
- Moderator
- Posts: 10170
- Joined: 04 May 2010, 18:38
- Znuny Version: 5.0.x
- Location: SouthWest Florida, USA
- Contact:
Re: ArticleStorageDB vs. ArticleStorageFS
Please read my previous post again.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
Re: ArticleStorageDB vs. ArticleStorageFS
Oh my bad
didn't read well

Re: ArticleStorageDB vs. ArticleStorageFS
FYI I'd moved ticket to junk queue and deleted it. After that, I rerun script and finally moved all attch to FS.
Re: ArticleStorageDB vs. ArticleStorageFS
I just had the same situation when migrating the article attachments out of the database...I don't know if this *stopped* or skipped for you. I would hope it skipped this.
got these error messages and had the script stop completly, had to use the force parameter to restart (pid-file not deleted).
[Wed Sep 17 13:46:26 2014][Error][Kernel::System::Ticket::TicketArticleStorageSwitch][7846] Not all files are moved! (TicketID:262/ArticleID:1905)!
[....]
[Wed Sep 17 13:47:55 2014][Error][Kernel::System::Ticket::TicketArticleStorageSwitch][7846] Not all files are moved! (TicketID:940/ArticleID:3600)!
Traceback (2050):
Module: Kernel::System::Ticket::TicketArticleStorageSwitch (OTRS 3.3.5) Line: 7846
Module: bin/otrs.ArticleStorageSwitch.pl (unknown version) Line: 160
So I checked the code at line 160, and found this:
Code: Select all
exit 1 if !$CommonObject{TicketObject}->TicketArticleStorageSwitch(
Code: Select all
print "FAILED exporting!\n" if !$CommonObject{TicketObject}->TicketArticleStorageSwitch(
-
- Znuny expert
- Posts: 213
- Joined: 04 Nov 2012, 23:58
- Znuny Version: OTRS 4.x
- Real Name: Esteban
- Company: NORTON DE COLOMBIA
Re: ArticleStorageDB vs. ArticleStorageFS
for the record, if you want to skip errors you dont need to change any code in otrs.ArticleStorageSwitch.pl
just execute it with -l argument
line 50
line 182
so if the -l argument is present, it wont exit
just execute it with -l argument
line 50
Code: Select all
"usage: otrs.ArticleStorageSwitch.pl -s ArticleStorageDB -d ArticleStorageFS [-c <JUST_SELECT_WHERE_CLOSE_DATE_IS_BEFORE> e. g. -c '2011-06-29 14:00:00' -C <JUST_SELECT_WHERE_CLOSE_IS_OLDER_IN_DAYS] e. g. -C '5' [-b sleeptime per ticket in microseconds] [-l liberal] [-f force]\n";
Code: Select all
exit 1 if !$Opts{l} && !$Success;
Re: ArticleStorageDB vs. ArticleStorageFS
AH! didn't realize liberal would equate to "ignore errors", but I guess I should have...eandrex wrote:for the record, if you want to skip errors you dont need to change any code in otrs.ArticleStorageSwitch.pl
just execute it with -l argument
now, I've got the files exported and stored in a nice hierarchy, but it seems I'm missing the link between them and their respective articles? Is there another syncing-script I should execute as well?