Unable to use localhost as the primary MySQL server location.

297 views
Skip to first unread message

Kenyatta Runnels

unread,
Jun 9, 2020, 6:29:05 PM6/9/20
to ResourceSpace
Hello,

Can someone assist me?

I am trying to install RS on my Synology NAS Box, but I can not get past the initial setup phase. It does not matter if I specify a location or not, the results are the same. Any help would be greatly appreciated.

Currently, using MariaDB 10
PHP version: 7.2.24


Daniel Bridgman

unread,
Apr 10, 2021, 4:20:14 PM4/10/21
to ResourceSpace
Greetings,

Has anyone figured out how to get past the /pages/setup.php RS localhost install alert on Synology NAS?

I've tried this on multiple Synology boxes (DSM 6.2), the installation of ResourceSpace (v.9.3 or 9.4) proceeds, directories (filestore, include, database) get populated, however, when logging back in attempting to fill out the initial installation form, there's no way past a MySQL base-URL error ... the perennial response: Test failed  (unable to verify MySQL). I can reach other databases via CLI, but not execute setup via the web form.

BTW: I've tried this both with direct system installs of MariaDB10/PHP 7,x/Apache2, as well as utilizing the Creecros ResourceSpace Docker container (tagged Latest) ... both fully install, but the result's always the same: unable to verify MySQL.

If someone's figured out what base MySQL base URL works we'd appreciate it.

Daniel Bridgman
Smith College

Mike Perry

unread,
Apr 11, 2021, 9:22:27 AM4/11/21
to ResourceSpace
Look at your config.php file in the includes folder. To what URL does the "$mysql_server = " statement point?

Mike Perry

unread,
Apr 11, 2021, 11:31:45 AM4/11/21
to ResourceSpace
Disregard previous post -- config.php is not created until the final installation is done.🙁

Is MySQL running during your install?

Daniel Bridgman

unread,
Apr 11, 2021, 1:04:32 PM4/11/21
to ResourceSpace
Mike,

Thanks much for your reply.

Yes, MySQL's running during install. I can verify it via command-line interaction with the host MySQL instance, although this is negotiated via Docker entry points so it's a bit complicated. I’ve used the db's root credential to assure MySQL 5.6's running/responsive (as per Creecros ResourceSpace container instructions). Everything goes smooth until I hit the web form ... setup of the RS database kicks me out after 5 failed verification attempts.

The odd part: I’ve successfully done ResourceSpace installs on other hosts (relying on various LAMP stacks) and localhost commonly works. With a NAS host on the other hand, since it's headless(?), it’s more complicated. Localhost is not accepted by the setup form's verification script. I’ve tried obvious permutations--fully qualified host name+port, IP address+port, 127.0.0.1+port(?), appending the MySQL database name, etc.--without luck.

Guess I’m looking for clues to what the form's expecting, so I can supply a URL that’s most likely to click. 

At this point I’m out of ideas, and stuck, I see a scattering of older posts from users attempting installs on NAS hosts … most un-resolved. Would love to solve this, and help inform future list members.

Best,
Daniel


Daniel Bridgman
Smith College
Northampton, MA

Mike Perry

unread,
Apr 11, 2021, 4:05:19 PM4/11/21
to ResourceSpace
Unfortunately I'm unfamiliar  with NAS hosts -- I've done successful installs on Ubuntu hosted and local servers, but never NAS. And I'm hardly a Linux guru -- know enough to get by!

RS has a KB entry for Synology installs -- but I suspect you've checked that out.

Daniel Bridgman

unread,
Apr 12, 2021, 11:06:15 AM4/12/21
to ResourceSpace
Mike,

Yes, studied RS’s Synology install KB info … it’s out-of-date, so not a help addressing this issue.

Here’s what the installation check says: 

PHP version: 7.3.15 (OK)
PHP config: '/etc/php7/php.ini'
GD version: bundled (2.1.0 compatible) (OK)
PHP.INI value for 'memory_limit': 200M (OK)
PHP.INI value for 'post_max_size': 100M (OK)
PHP.INI value for 'upload_max_filesize': 100M (OK)
Write access to config directory: (OK)
Write access to storage directory: (OK)

Checked my previous ResourceSpace install config.php (from version 7.8--thanks for that suggestion); that succeeded with only “localhost" for MySQL server.
Version 9.x’s setup.php cannot proceed with any localhost combo or any other MySQL server name I’m able to throw at it.

Synology NAS hosts can be finicky when localhost is used, however, 127.0.0.1 (loopback) normally works in its stead. Not in this instance.

I’m trying to work backward from my older working install, but it’s slow going.

A clue I’m contemplating is the warning: license.txt is not readable. Not sure why it cannot read its included license file … installation check says: config directory's read/writeable. Am I missing something obvious?

Sign,
Daniel

Daniel Bridgman
Smith College
Northampton, MA

Mike Perry

unread,
Apr 12, 2021, 11:25:15 AM4/12/21
to ResourceSpace
I trust by config directory you mean the root install dir. That's where license.txt is located in my installations. Also -- are all permissions correct? I'm just spitballing here. . .
Message has been deleted

Daniel Bridgman

unread,
May 24, 2021, 10:51:53 AM5/24/21
to resour...@googlegroups.com
Johnny,

Did solve the RS setup.php mystery:

What worked with ResourceSpace v7.8–on a Red Hat Enterprise host–was the simple default: localhost … bit that didn’t work on other hosts.

When I attempted setup of RS v.9.5 on a different server it wouldn't accept “localhost” as input to the MySQL_PATH variable. Failed miserably, repeatedly, with no explanation.

On Mike’s suggestion examined the old setup.php file that's stored in the include folder of my previous successful install.
Discovered not only would localhost choke, but that a port number would be required as well.

My current host, a Synology NAS (headless appliance) running Docker containers, executes setup.php inside a mysql-service container. That entity interprets “localhost" as a pointer to itself–NOT to the public-facing physical box’s network stack.

My solution: use a service label (of the container): resourcespace-mysql: 3306  (.e., the port MariaDB10 listens on).

Depending upon your host, its database backend, will determine what setup.php will except for MYSQL_PATH. Took quite a bit of trial and (mostly) error.

With luck this helps,
Daniel


Daniel Bridgman
Smith College


On May 21, 2021, at 4:43 PM, Johnny K <kattou...@gmail.com> wrote:


did you manage to get past the setup? i am stuck at same stage.
-- 
ResourceSpace: Open Source Digital Asset Management
http://www.resourcespace.com
--- 
You received this message because you are subscribed to a topic in the Google Groups "ResourceSpace" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/resourcespace/g1VDm3BDlI8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to resourcespac...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/resourcespace/1cf2cf90-b091-4b43-8869-13d981e5f724n%40googlegroups.com.

J. Manuel Velasco

unread,
May 24, 2021, 3:32:35 PM5/24/21
to ResourceSpace
Hello,
Just a quick suggestion, try to use the IP, 127.0.0.1

Maybe like this it works.
Could be the dB user is restricted to access only from the IP and not allowed from the hostname.

Cheers,
•_-

--
ResourceSpace: Open Source Digital Asset Management
http://www.resourcespace.com
---
You received this message because you are subscribed to the Google Groups "ResourceSpace" group.
To unsubscribe from this group and stop receiving emails from it, send an email to resourcespac...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/resourcespace/d7dfef62-4488-4bcd-a8fa-20affcbbecd9o%40googlegroups.com.

Daniel Bridgman

unread,
May 25, 2021, 8:16:51 AM5/25/21
to resour...@googlegroups.com
Loopback (127.0.0.1) may work, that is, if you’re installing on a regular server.

If you happen to be doing anything irregular, like deploying Docker containers, AWS, VM, etc., it won’t.

That's because each VM or container loops back to itself, so 127.0.0.1 doesn’t resolve properly (i.e., breaks setup's test, at least it does on NAS hosts like mine) … YMMV.

My servers execute setup.php in (isolated) containers, so 127.0.0.1 doesn't work as ResourceSpace's MYSQL_PATH variable. That's because it references only the Apache micro-service–where setup.php gets executed.
I have to call micro-services by label names +  MariaDB 10’s port (3306) to pass setup.php muster.

But you’re correct, if the MySQL user's restricted localhost may fail, while 127.0.0.1 can resolve/ pass the setup.php test.

Regards,
Daniel

Daniel Bridgman
Smith College


On May 24, 2021, at 3:32 PM, J. Manuel Velasco <jmanuel...@gmail.com> wrote:

Hello,
Just a quick suggestion, try to use the IP, 127.0.0.1

Maybe like this it works.
Could be the dB user is restricted to access only from the IP and not allowed from the hostname.

Cheers,
•_-

El mié., 10 jun. 2020 0:29, Kenyatta Runnels <knr...@gmail.com> escribió:
Hello,

Can someone assist me?

I am trying to install RS on my Synology NAS Box, but I can not get past the initial setup phase. It does not matter if I specify a location or not, the results are the same. Any help would be greatly appreciated.

Currently, using MariaDB 10
PHP version: 7.2.24

<Auto.png>

--
ResourceSpace: Open Source Digital Asset Management
http://www.resourcespace.com
---
You received this message because you are subscribed to the Google Groups "ResourceSpace" group.
To unsubscribe from this group and stop receiving emails from it, send an email to resourcespac...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/resourcespace/d7dfef62-4488-4bcd-a8fa-20affcbbecd9o%40googlegroups.com.

--
ResourceSpace: Open Source Digital Asset Management
http://www.resourcespace.com
---
You received this message because you are subscribed to a topic in the Google Groups "ResourceSpace" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/resourcespace/g1VDm3BDlI8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to resourcespac...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/resourcespace/CAEv3vh25tgBCup6C7gXgVcwLr-ziDOSeqpqzQnGBk189HBDjfQ%40mail.gmail.com.

Reply all
Reply to author
Forward
0 new messages