/mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post your questions about Web Server usage and Apache + PHP + MySQL/SQLite web applications.
Post Reply
FreshMike
Starting out
Posts: 41
Joined: Sat Jan 28, 2012 8:03 pm

/mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by FreshMike »

Hi All,

I have a T-112 Qnap NAS and I'm running Apps like umurmur, transmission, and other which have a web console. After the upgrade to the latest Qnap Firmware 4.3.3 I can't reach any on the web consoles. When trying to access the app console I'm getting either such message:
Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at admin@NAS to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.
or a 404 message.

The Web Server works as I can get to the myphpadmin console.

The .htaccess* files in the Apps have following entries:

Code: Select all

AuthName "Mumble Server Restricted Access"
AuthType Basic
#       AuthUserFile /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd
or

Code: Select all

[/share/Web/transmission] # cat htaccess
AuthName "Transmission - Admin Restricted Access (Use NAS admin credentials)"
AuthType Basic
#       AuthUserFile /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd
AuthUserFile /mnt/HDA_ROOT/.config/shadow
The HDA_ROOT folder doesn't have any rootfs folder:

Code: Select all

[/mnt/HDA_ROOT] # ls -la
drwxr-xr-x   11 admin    administ      4096 May 12 08:31 ./
drwxr-xr-x    7 admin    administ      1024 May 12 15:37 ../
lrwxrwxrwx    1 admin    administ        26 Aug 23  2011 .centerim -> /share/HDA_DATA/.@centerim/
-rw-r--r--    1 admin    administ       104 May 12 08:31 .conf
drwxr-xr-x   38 admin    administ      4096 May 12 19:29 .config/
drwxrwxrwx    2 admin    administ      4096 Apr 18 20:47 .inited/
drwxr-xr-x    5 admin    administ      4096 May 12 20:04 .logs/
drwxr-xr-x    3 admin    administ      4096 Jan  9 11:07 .qpkg/
drwxrwxrwx    8 admin    administ      4096 Aug 24  2011 .spool/
-rw-r--r--    1 admin    administ         0 Jun 13  2012 badblocks.log
-rw-r--r--    1 admin    administ    201728 Oct 24  2014 ds.db
drwx------    2 admin    administ     16384 Aug 24  2011 lost+found/
-rw-rw-rw-    1 httpdusr administ         0 Dec 27  2012 photo_scan.record
drwxr-xr-x    2 admin    administ      4096 Apr 18 20:27 ssl_lib/
lrwxrwxrwx    1 admin    administ        24 Apr 18 20:49 twonkymedia -> /mnt/ext/opt/twonkymedia/
drwxr-xr-x    2 admin    administ      4096 Apr 18 20:43 update/
drwxr-xr-x    3 admin    administ      4096 May 12 15:39 update_pkg/
Any ideas what's wrong ?
Thanks
User avatar
OneCD
Guru
Posts: 12144
Joined: Sun Aug 21, 2016 10:48 am
Location: "... there, behind that sofa!"

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by OneCD »

FreshMike wrote:

Code: Select all

[/share/Web/transmission] # cat htaccess
AuthName "Transmission - Admin Restricted Access (Use NAS admin credentials)"
AuthType Basic
#       AuthUserFile /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd
AuthUserFile /mnt/HDA_ROOT/.config/shadow
Not an answer to your problem (sorry), but some info. Any line that starts with '#' is ignored.

So in your example above, [AuthUserFile] is set to [/mnt/HDA_ROOT/.config/shadow]. ;)

ImageImageImageImageImageImageImageImageImageImageImageImageImageImageImageImageImageImage
FreshMike
Starting out
Posts: 41
Joined: Sat Jan 28, 2012 8:03 pm

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by FreshMike »

Ah damn you are right and I'm an idiot. But found the issue:

Enabled the Apache logs:

Code: Select all

[Fri May 12 20:19:52.494565 2017] [core:alert] [pid 23134] [client 192.168.1.7:60824] /share/Web/transmission/.htaccess: Invalid command 'AuthGroupFile', perhaps misspelled or defined by a module not included in the server configuration
Added LoadModule authz_groupfile_module modules/mod_authz_groupfile.so to file: /mnt/HDA_ROOT/.config/apache/extra/apache-default-modules.conf

Now I'm able to the login box and login to the web consoles.
User avatar
schumaku
Guru
Posts: 43579
Joined: Mon Jan 21, 2008 4:41 pm
Location: Kloten (Zurich), Switzerland -- Skype: schumaku
Contact:

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by schumaku »

FreshMike wrote:But found the issue...
QNAP has clearly broken the continuity with the Apache update. I've filed a feature request direct into their system for re-adding the authz_groupfile_module by default, as this will (and already has) caused an abnormal number of forum posts. And not everyone has the experience for analysing the issue and adding the missing module to the Apache config.

For backing, please file a ticket on https://helpdesk.qnap.com/ backing this issue, mention Mantis BT ID 19859: [4.3.3.0173 and before] Web Server Service: Add authz_groupfile_module modules/mod_authz_groupfile.so to Default Configuration.

Regards,
-Kurt
ensignvorik
Easy as a breeze
Posts: 365
Joined: Sat Jul 14, 2012 8:24 pm

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by ensignvorik »

schumaku wrote:
FreshMike wrote:But found the issue...
QNAP has clearly broken the continuity with the Apache update. I've filed a feature request direct into their system for re-adding the authz_groupfile_module by default, as this will (and already has) caused an abnormal number of forum posts. And not everyone has the experience for analysing the issue and adding the missing module to the Apache config.

For backing, please file a ticket on https://helpdesk.qnap.com/ backing this issue, mention Mantis BT ID 19859: [4.3.3.0173 and before] Web Server Service: Add authz_groupfile_module modules/mod_authz_groupfile.so to Default Configuration.

Regards,
-Kurt
Done.
Unless I'm being blind, I can't find the setting to change what kind of QNAP I have on my profile. I now own a TS-253A
FreshMike
Starting out
Posts: 41
Joined: Sat Jan 28, 2012 8:03 pm

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by FreshMike »

schumaku wrote:
FreshMike wrote:But found the issue...
QNAP has clearly broken the continuity with the Apache update. I've filed a feature request direct into their system for re-adding the authz_groupfile_module by default, as this will (and already has) caused an abnormal number of forum posts. And not everyone has the experience for analysing the issue and adding the missing module to the Apache config.

For backing, please file a ticket on https://helpdesk.qnap.com/ backing this issue, mention Mantis BT ID 19859: [4.3.3.0173 and before] Web Server Service: Add authz_groupfile_module modules/mod_authz_groupfile.so to Default Configuration.

Regards,
-Kurt
Done,
Ticket ID #HNV-470-74794
ampapa
Know my way around
Posts: 126
Joined: Sat Dec 03, 2011 7:47 am

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by ampapa »

Just a follow up to this thread if relevant but I also had to add in addition to the above the following to the apache-default-modules.conf to fix problems with the 4.4.3 upgrade
Added LoadModule authz_host_module modules/mod_authz_host.so to file: /mnt/HDA_ROOT/.config/apache/extra/apache-default-modules.conf
ampapa,
User avatar
schumaku
Guru
Posts: 43579
Joined: Mon Jan 21, 2008 4:41 pm
Location: Kloten (Zurich), Switzerland -- Skype: schumaku
Contact:

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by schumaku »

ampapa wrote: I also had to add in addition to the above the following to the apache-default-modules.conf to fix problems with the 4.4.3 upgrade
QTS 4.3.3 does not require authz_host_module - probably some either QNAP repository or 3rd party Web applications might require it. Which one required loading authz_host_module?
kofoster
Starting out
Posts: 22
Joined: Sun Nov 18, 2012 12:15 pm

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by kofoster »

Can someone help me with this?

I have a TS-219P II. I am experiencing this issue since upgrading firmware, to 4.3.3.0188, last night. I follow the instructions in "[TUTORIAL] How to edit your apache.conf file" to update /mnt/HDA_ROOT/.config/apache/extra/apache-default-modules.conf with statement "LoadModule authz_host_module modules/mod_authz_host.so" but the problem does not go away. Strangely, when I restart using "/etc/init.d/./Qthttpd.sh restart" the web server restarts but when I check the /mnt/HDA_ROOT/.config/apache/extra/apache-default-modules.conf the statement I added is no longer there. I am not sure what I am doing wrong.

Help.
Karl
QNAP TS-219PII - Firmware Version 4.3.3.0188
User avatar
schumaku
Guru
Posts: 43579
Joined: Mon Jan 21, 2008 4:41 pm
Location: Kloten (Zurich), Switzerland -- Skype: schumaku
Contact:

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by schumaku »

Karl,

Put the LoadModule authz_host_module modules/mod_authz_host.so to /etc/default_config/apache-default-modules.conf instead.

-Kurt
kofoster
Starting out
Posts: 22
Joined: Sun Nov 18, 2012 12:15 pm

Re: /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd missing after 4.3.3 upgrade

Post by kofoster »

Thanks Kurt,

That worked but did not resolve the underlying problem. My web sites are still not operating properly. I opened another topic in the forum based on other messages I am seeing. Firmware 4.3.3.0188 seems to have really broken my QNAP. Is there any way to rollback a firmware update? Even if possible, will that cause more issues than it might solve?
Karl
QNAP TS-219PII - Firmware Version 4.3.3.0188
Post Reply

Return to “Web Server & Applications (Apache + PHP + MySQL / SQLite)”