Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Just a quick question:

How can I prevent nginx from trimming file name with ... in listing directory?

share|improve this question
up vote 5 down vote accepted

It looks like the only way to that is to edit the source code. The following #define in src/http/modules/ngx_http_autoindex_module.c have to be changed:


Maybe something else needs to be tweaked too, but that's what I saw at first glance.

share|improve this answer
This could be time consuming. You sure there is no other way around this? If not I could start write a small php script. – DucDigital Sep 12 '11 at 16:27
There's no other way, maximal length is hard-coded with the #define above. Yep, external script for directory listing may be a better solution. – Vladimir Blaskov Sep 12 '11 at 16:32

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.