# Mariadb/nginx failed to be detected

**URL:** <https://forum.ghost.org/t/mariadb-nginx-failed-to-be-detected/27479>\
**Category:** Bugs\
**Created:** [December 21, 2021, 9:06pm UTC](https://forum.ghost.org/t/mariadb-nginx-failed-to-be-detected/27479 "2021-12-21T21:06:31Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kris](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/kris/32/4215_2.png) [@Kris](https://forum.ghost.org/u/Kris)\
**Post date:** [December 21, 2021, 9:06pm UTC](https://forum.ghost.org/t/mariadb-nginx-failed-to-be-detected/27479/1 "2021-12-21T21:06:31Z")

</div>

Bug / Issue documented and reported on ghost github, posting here for visibility as it seems multiple users with different configurations are having similar issues:

> <https://github.com/TryGhost/Ghost-CLI/issues/1586>
>
> Trying to set up ghost on a pi 4, 4GB, running piOS bullseye, 64bit using mariad…b and nginx
> Having trouble with \` ghost install \` failing to find the running services for both mysql and nginx
> 
> I have reproduced this twice with clean installations of the OS image, skipping hardening steps like firewall just to test a successful install
> \- install OS
> \- install nginx, mariadb, node.js
> \- update root mysql password, create ghost database/user and set perms, create system user/ghost directory and set perms
> \- run \` ghost install \`
> 
> When running \` ghost install \` I get the following:
> \`\`\`
> /var/www/ghost $ ghost install
> ✔ Checking system Node.js version - found v16.13.1
> ℹ Ensuring user is not logged in as ghost user \[skipped\]
> ℹ Checking if logged in user is directory owner \[skipped\]
> ✔ Checking current folder permissions
> Local MySQL install was not found or is stopped. You can ignore this if you are using a remote MySQL host.
> Alternatively you could:
> a) install/start MySQL locally
> b) run \`ghost install --db=sqlite3\` to use sqlite
> c) run \`ghost install local\` to get a development install using sqlite3.
> ? Continue anyway? No
> ✖ Checking for a MySQL installation
> ✔ Validating config
> ✔ Checking content folder ownership
> ✔ Checking memory availability
> ✔ Checking binary dependencies
> ✔ Checking free space
> One or more errors occurred.
> 
> 1) Checking for a MySQL installation
> 
> Message: MySQL check failed.
> \`\`\`
> 
> I created the link and ran the script provided in this comment:
> https://github.com/TryGhost/Ghost-CLI/issues/460#issuecomment-890541435
> 
> When this script is running, I am able to get passed the mysql checks, but then the installer fails to find nginx
> 
> \`\`\`
> /var/www/ghost $ ghost install
> ✔ Checking system Node.js version - found v16.13.1
> ✔ Checking logged in user
> ✔ Checking current folder permissions
> System checks failed with message: 'Linux version is not Ubuntu 16, 18, or 20'
> Some features of Ghost-CLI may not work without additional configuration.
> For local installs we recommend using \`ghost install local\` instead.
> ? Continue anyway? Yes
> System stack check skipped
> ℹ Checking system compatibility \[skipped\]
> ✔ Checking for a MySQL installation
> ✔ Checking memory availability
> ✔ Checking free space
> ✔ Checking for latest Ghost version
> ✔ Setting up install directory
> ✔ Downloading and installing Ghost v4.25.1
> ✔ Finishing install process
> ? Enter your blog URL: http://localhost:2368
> ? Enter your MySQL hostname: localhost
> ? Enter your MySQL username: \[hidden\]
> ? Enter your MySQL password: \[hidden\]
> ? Enter your Ghost database name: ghost
> ✔ Configuring Ghost
> ✔ Setting up instance
> + sudo useradd --system --user-group ghost
> ? Sudo Password \[hidden\]
> + sudo chown -R ghost:ghost /var/www/ghost/content
> ✔ Setting up "ghost" system user
> ℹ Setting up "ghost" mysql user \[skipped\]
> Nginx is not installed. Skipping Nginx setup.
> ℹ Setting up Nginx \[skipped\]
> Nginx setup task was skipped, skipping SSL setup
> ℹ Setting up SSL \[skipped\]
> ? Do you wish to set up Systemd? No
> Systemd setup skipped, reverting to local process manager
> ℹ Setting up Systemd \[skipped\]
> ? Do you want to start Ghost? No
> ℹ Starting Ghost \[skipped\]
> 
> Ghost uses direct mail by default. To set up an alternative email method read our docs at https://ghost.org/docs/config/#mail
> 
> \------------------------------------------------------------------------------
> 
> Ghost was installed successfully! To complete setup of your publication, visit: 
> 
> http://localhost:2368/ghost/
> \`\`\`
> 
> The required services are configured and running:
> \`\`\`
> $ systemctl --type=service
> ...
> mariadb.service loaded active running MariaDB 10.5.12 database server
> ...
> nginx.service loaded active running A high performance web server and a reverse proxy server
> ...
> \`\`\`
> 
> Unless the script from the comment is running, I cannot pass the mysql checks - I cannot find or figure out a solution to passing the nginx checks to do a complete setup and I am not sure what changes are made during the nginx steps to make the changes manually - any insights into this would be greatly appreciated. Please let me know if there is any other information I could provide.
> 
> Debug Information:
> OS: Debian GNU/Linux, v11
> Node Version: v16.13.1
> Ghost Version: 4.25.1
> Ghost-CLI Version: 1.18.1
> Environment: production
> Command: 'ghost install'
> 
> \- \[✔\] Tried to find help in the forum & docs
> \- \[✔ \] Checked for existing issues
> \- \[❌\] Attached log file (no 'additional errors' to note)
> \- \[✔\] Provided technical details incl. operating system

tl;dr: mariadb fails the mysql check, you can fix this by editing the doctor check script as noted in a comment on a related issue.

Setup goes thru until the nginx checks, those fail and setup skips nginx/ssl config

Retrying with: ghost setup nginx  
…fails with the same result

No updates on my or related issues in weeks. Does anyone have any insight on a fix or potential workaround?

---

<div class="post-metadata">

**Author:** ![pactole](https://avatars.discourse-cdn.com/v4/letter/p/e36b37/32.png) [@pactole](https://forum.ghost.org/u/pactole)\
**Post date:** [January 12, 2022, 8:57pm UTC](https://forum.ghost.org/t/mariadb-nginx-failed-to-be-detected/27479/2 "2022-01-12T20:57:53Z")

</div>

Hello Kris,  
I have the same config Debian 11 and the same problem.  
I’ve found a “workaround” to the problem by downgrading my ghost-cli to the 1.17.0 by doing a  
npm i ghost-cli@1.17.0 -g  
Best

---

<div class="post-metadata">

**Author:** ![UnrealDavid](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/unrealdavid/32/17155_2.png) [@UnrealDavid](https://forum.ghost.org/u/UnrealDavid)\
**Post date:** [March 21, 2022, 9:36pm UTC](https://forum.ghost.org/t/mariadb-nginx-failed-to-be-detected/27479/3 "2022-03-21T21:36:24Z")

</div>

Skip the MySQL check. For Nginx install the basic one that comes with your package manager, then let it make the site config file, then update Nginx after. Best suggestion would be to ignore this and make your own Nginx config and use Certbot to get your certs.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex015/uploads/ghost2/original/2X/b/ba9ce5100b8bb264586f4f572545596b2ce3f081.png) [@system](https://forum.ghost.org/u/system)\
**Post date:** [June 19, 2022, 9:37pm UTC](https://forum.ghost.org/t/mariadb-nginx-failed-to-be-detected/27479/4 "2022-06-19T21:37:13Z")

</div>

Closed on June 19, 2022, 9:37pm UTC

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
