Hi there

I am currently migrating a 1.11 installation from a Windows to a Linux machine. After transferring all data and the database I was unable to pull tickets from a mailbox or create new ones. I would always get the I/O error pointing usually to an issue with user rights. After havin spent a couple hours on fixing rights that did not need fixing I found that the issue I am having is with the case sensitive folder and file structure of the attachments plugin to store these in the file system.

On the windows machine it simply fell back to creating folders with capital letters and storing all files there. Now on the Linux machine it starts creating folders with small letters as well but still stores the files in the folders with capital letters. When the system wants to read the newly created files back, it gets into trouble.

What I figure is, that I have two problems:

  1. File creation happens somehow in the existing folders with capital letter, while new folders with small letters are created but not used. When such a file has been created the system looks in the newly created folder with small letter but finds nothing. If I manuall copy the file there everything works.
    1. As soon as the first issue is resolved I would probably need to sort alle files and move them to the appropriate folders.

Anyone faced a similar isse before and has resolved this? I think I can tell the webserver to be either case sensitve or not - but would that help? Could I create something like symlinks to dublicate the exisiting files? Am I completely on the wrong track and there is a simple answer?

Help is much appreciated.

System Info
Ticket-System 1.11 (I know, no longer supported. Plan is to update after migration)
Apache/2.4.29 (Ubuntu) (running as Apache module)
MySQL-Version 5.7.28
PHP-Version 7.2.24-0ubuntu0.18.04.2

Bonus question: Would running the update to a current version prior to moving the files do any good? Can't imagine why, as the plugin does not seem to have been updated.

So, I figured to try and enable "mod_speling" and configured the host to "CheckCaseOnly on" while keeping "CheckSpelling off".

EDIT: While at first this seemed to do the trick, it actually does not. So I am back at the original problem where files cannot be found.

I have now created all the lower case folders missing on the new machine and moved all files starting with a lower case character to these folders.
And finally! At least all existing attachments in tickets are found again and can be accessed. Before only those with upper case attachments where found.

Also, now I get a new error message when creating new tickets with a new attachment:
/tmp/phpiLxx2Z: Unable to move file

So, it seems I actually do still have a permission problem on the temporary directory.
The temporary folder was the system default so far. Currently the php.ini is configured to point upload_tmp_dir and sys_tmp_dir to /var/tmp and this folder is currently set to 777
However, I still get the error message.

I feel I am missing something obvious here... something to do with the apache user maybe?

SOLVED - In the end I figured out that the attachment folder including everything below needs to be actually owned by the apache user and not only the user group. Permission alone seems not enough - it has to be ownership.

So two steps, in case anyone else has the same issue when migrating Windows to Linux:

  • split the files in the attachment folder so that there exist lower and upper case folders from A - z and move the files according to the case of the first letter in the filename
  • change ownership of the attachment folder recursively to the apache user.

Shall I mark this as resolved and close the thread?

ntozier changed the title to [resolved] Case sensitive filenames cause problems migrating from win to linux.
Write a Reply...