Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
apache-2.4.7 doesn't show compressed manuals
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
toralf
Developer
Developer


Joined: 01 Feb 2004
Posts: 3922
Location: Hamburg

PostPosted: Wed Mar 05, 2014 7:24 pm    Post subject: apache-2.4.7 doesn't show compressed manuals Reply with quote

I do know, that it worked before,but now I do get :
"Not Found

The requested URL /manual/index.html.en was not found on this server.
"

And yes - there's no index.html.en, just index.html.en.bz2 and bunzip'ing of that file works and brought bakc the manual page - but now I'm wondering,whether the installation of apache2 was wrong wrt to uncompressing the files or if I do miss a apache module to do the uncompress on the fly ?

FWIW emerge --info gives :
Code:
www-servers/apache-2.4.7 was built with the following:
USE="doc ldap ssl threads -debug (-selinux) -static -suexec" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_core authn_dbm authn_file authz_core authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir env expires ext_filter file_cache filter headers include info log_config logio mime mime_magic negotiation rewrite setenvif socache_shmcb speling status unique_id unixd userdir usertrack vhost_alias -access_compat -asis -auth_digest -authn_dbd -cache_disk -cern_meta -charset_lite -dbd -dumpio -ident -imagemap -lbmethod_bybusyness -lbmethod_byrequests -lbmethod_bytraffic -lbmethod_heartbeat -log_forensic -proxy -proxy_ajp -proxy_balancer -proxy_connect -proxy_fcgi -proxy_ftp -proxy_http -proxy_scgi -ratelimit -remoteip -reqtimeout -slotmem_shm -substitute -version" APACHE2_MPMS="-event -itk -peruser -prefork -worker"
Update: Ah - 2.4.6 has uncompressed files under /usr/share/doc/apache-2.4.6...., but 2.4.7 now let them compressed, but what I do have now to change here ?
Back to top
View user's profile Send private message
666threesixes666
Veteran
Veteran


Joined: 31 May 2011
Posts: 1248
Location: 42.68n 85.41w

PostPosted: Wed Mar 05, 2014 8:39 pm    Post subject: Reply with quote

personally id purge them &

http://httpd.apache.org/docs/2.4/

only...
Back to top
View user's profile Send private message
toralf
Developer
Developer


Joined: 01 Feb 2004
Posts: 3922
Location: Hamburg

PostPosted: Wed Mar 05, 2014 9:17 pm    Post subject: Reply with quote

666threesixes666 wrote:
personally id purge them &

http://httpd.apache.org/docs/2.4/

only...
Well, in the mean while I'm interested how to deal with compressed files too - and mod_defalte seems to be the answer, but I do not know, how to tweak /etc/apache2/modules.d/00_apache_manual.conf
Back to top
View user's profile Send private message
666threesixes666
Veteran
Veteran


Joined: 31 May 2011
Posts: 1248
Location: 42.68n 85.41w

PostPosted: Wed Mar 05, 2014 10:04 pm    Post subject: Reply with quote

http://youtu.be/JLJQXiIlj8w <--- totally reminds me of my linux boxes after fixing wiki pages for people.... ill start to look at it for you. my 2.2.25 by default supports deflate. 2.2.25 doesnt have a 00 mod deflate configuration. ill start looking around about this because i deem it worthy of investigation since server real estate is valuable, and you can host an absurd gang of websites on 1 apache nix box via named based hosts.

http://httpd.apache.org/docs/2.4/mod/mod_deflate.html

after emerging apache 2.4.7 with doc use flag enabled

linking

ln -s /usr/share/doc/apache-2.4.7/manual/ /var/www/localhost/htdocs/manual

& pointing browser @ localhost/manual i get

Code:

# GENERATED FROM XML -- DO NOT EDIT URI: index.html.da Content-Language: da Content-type: text/html; charset=ISO-8859-1 URI: index.html.de Content-Language: de Content-type: text/html; charset=ISO-8859-1 URI: index.html.en Content-Language: en Content-type: text/html; charset=ISO-8859-1 URI: index.html.es Content-Language: es Content-type: text/html; charset=ISO-8859-1 URI: index.html.fr Content-Language: fr Content-type: text/html; charset=ISO-8859-1 URI: index.html.ja.utf8 Content-Language: ja Content-type: text/html; charset=UTF-8 URI: index.html.ko.euc-kr Content-Language: ko Content-type: text/html; charset=EUC-KR URI: index.html.pt-br Content-Language: pt-br Content-type: text/html; charset=ISO-8859-1 URI: index.html.tr.utf8 Content-Language: tr Content-type: text/html; charset=UTF-8 URI: index.html.zh-cn Content-Language: zh-cn Content-type: text/html; charset=UTF-8


same behavior for you?

/etc/apache2/modules.d/00_apache_manual.conf is confusing me....
Back to top
View user's profile Send private message
Atom2
Apprentice
Apprentice


Joined: 01 Aug 2011
Posts: 185

PostPosted: Sat Jul 26, 2014 9:12 pm    Post subject: Reply with quote

I do have the same problem as the OP - albeit with version 2.2.27 (the latest stable version in the portage tree): Manual pages simply don't work and the error message also states (rightly) that the requested URL was not found, which is because only .bz2 compressed (different language) versions of all files are available.

I understand that a solution would be to recursively uncompress all necessary files and then it should work. I'd however prefer to have a (general) solution that is able to uncompress on the fly in memory and then deliver the uncompressed page to the client browser.
666threesixes666 wrote:
ln -s /usr/share/doc/apache-2.4.7/manual/ /var/www/localhost/htdocs/manual

& pointing browser @ localhost/manual i get

Code:

# GENERATED FROM XML -- DO NOT EDIT URI: index.html.da Content-Language: da Content-type: text/html; charset=ISO-8859-1 URI: index.html.de Content-Language: de Content-type: text/html; charset=ISO-8859-1 URI: index.html.en Content-Language: en Content-type: text/html; charset=ISO-8859-1 URI: index.html.es Content-Language: es Content-type: text/html; charset=ISO-8859-1 URI: index.html.fr Content-Language: fr Content-type: text/html; charset=ISO-8859-1 URI: index.html.ja.utf8 Content-Language: ja Content-type: text/html; charset=UTF-8 URI: index.html.ko.euc-kr Content-Language: ko Content-type: text/html; charset=EUC-KR URI: index.html.pt-br Content-Language: pt-br Content-type: text/html; charset=ISO-8859-1 URI: index.html.tr.utf8 Content-Language: tr Content-type: text/html; charset=UTF-8 URI: index.html.zh-cn Content-Language: zh-cn Content-type: text/html; charset=UTF-8


same behavior for you?

In essence yes: I had to symlink to another name (manual_1 instead of manual in the htdocs dir) as otherwise the (not working)
Code:
/etc/apache2/modules.d/00_apache_manual.conf
jumped in and reverted back to the not found error message described above. But other than that pointing to manual_1 provided the same output as yours - which in my POV is reasonable as there is a plain text file named index.html under /usr/share/doc/apache-2.2.27/manual/ containing exactly that information.

Regards Atom2
Back to top
View user's profile Send private message
Atom2
Apprentice
Apprentice


Joined: 01 Aug 2011
Posts: 185

PostPosted: Sun Jul 27, 2014 11:14 pm    Post subject: Reply with quote

I have done a bit more of digging and in essence, I think this is a bug of the ebuild which I have filed here.

To sum up: Standard ebuilds compress files under /usr/share/doc, /usr/share/info, and /usr/share/man and exclude files under /usr/share/doc/${PF}/html using bzip2 (unless disabled/changed to another compression program by changing/assigning a value to the variable PORTAGE_COMPRESS in /etc/portage/make.conf).
Furthermore the compression also excludes certain files based upon their suffixes which can be specified through PORTAGE_COMPRESS_EXCLUDE_SUFFIXES in /etc/portage/make.conf and which defaults to
Code:
PORTAGE_COMPRESS_EXCLUDE_SUFFIXES="gif htm[l]? jp[e]?g pdf png"

Unfortunately neither of those mechanisms would handle the apache manual files located under /usr/share/doc/apache-version/manual because (1) they are either in the wrong directory or (2) they have the wrong suffix (e.g. file.html.lang where the suffix is "lang" and it denotes the language the file is in).

Changing PORTAGE_COMPRESS_EXCLUDE_SUFFIXES would not work either because it only matches against the portion of the file name which follows the last period character - so matching against "htm[l].lang" would not work and just "lang" might be to wide and therefore may have other undesired side-effects.

There is however a cure provided I have managed to understad the EAPI documentation correctly: It requires changing the ebuild such that it would need to include a line similar to
Code:
docompress -x /usr/share/doc/"${PF}"/manual
in order to exclude all files under /usr/share/doc/apache-version/manual from being compressed.

I hope that makes sense and let's see what comments the bug report gets.

Regards Atom2


BTW: I have temporarily solved the issue by adding
Code:
PORTAGE_COMPRESS=""
to my /etc/portage/make.conf and re-emerged apache: For new emerges that change simply prevents any files in /usr/share/doc, /usr/share/info, and /usr/share/man from being compressed and as a side-effect also aids in grepping through those directories. As I do use btrfs with compression turned on, all files will anyways be compressed (albeit not as highly as with bzip2, but I can live with that).
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum