# Install without nginx? Goal: magento 2.4 install

**URL:** <https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326>\
**Category:** Cron Jobs\
**Created:** [April 22, 2021, 2:31pm UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326 "2021-04-22T14:31:44Z")\
**Posts on this page:** 8\
**Page:** 2

<div class="post-metadata">

**Author:** ![eris](https://forum.hestiacp.com/user_avatar/forum.hestiacp.com/eris/32/1241_2.png) [@eris](https://forum.hestiacp.com/u/eris)\
**Post date:** [April 24, 2021, 4:49pm UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326/21 "2021-04-24T16:49:08Z")

</div>

We rebuild crontab -I every time Hestia updates…

---

<div class="post-metadata">

**Author:** ![emeeder](https://forum.hestiacp.com/letter_avatar_proxy/v4/letter/e/a587f6/32.png) [@emeeder](https://forum.hestiacp.com/u/emeeder)\
**Post date:** [April 24, 2021, 8:37pm UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326/22 "2021-04-24T20:37:30Z")

</div>

Hi Falzo. Thanks for pointing that out. I got that code from a tutorial of someone who was likely settingup a standalone VPS for Magento. Not really what we would all do here within Hestiacp.

Sorry for the error in that instruction. I really am just starting out at this. And don’t worry, this website/VPS is only for me. But I do want to learn how to do things properly.

so this is the problem line?  
sudo chown -R :www-data .

I did run all the code under panel user: magento

is there a quick way to correct the privileges?

eris - ok…thats impressive! so does that run and install everything? what needs to be preinstalled to run that script?  
I see at the end you set up cron job in the panel? I guess that will work the same way, except you can see it as a cron job.

---

<div class="post-metadata">

**Author:** ![eris](https://forum.hestiacp.com/user_avatar/forum.hestiacp.com/eris/32/1241_2.png) [@eris](https://forum.hestiacp.com/u/eris)\
**Post date:** [April 24, 2021, 8:47pm UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326/23 "2021-04-24T20:47:48Z")

</div>

> [@emeeder](#):
>
> so this is the problem line?  
> sudo chown -R :www-data .

chown shouldn’t be needed just make sure you use the commands as the user…

> [@emeeder](#):
>
> eris - ok…thats impressive! so does that run and install everything? what needs to be preinstalled to run that script?

You still need to setup your server as “required” for Magento with all the software required.  
It also checks if the Redis database provided is not in use what could cause performance issues.

And run the script as the root user…

I have also an “magento” package + the following script in the same folder with the same name. (Instead .pkg it is .sh) (Located in /usr/local/hestia/data/packages/)

And it sets up the user correctly.

```
#/bin/bash

v-add-user-composer "$1"
v-change-user-php-cli "$1" "7.4"

```

> [@emeeder](#):
>
> I see at the end you set up cron job in the panel? I guess that will work the same way, except you can see it as a cron job.

Yes also any updates will not overwrite any thing when needed…

---

<div class="post-metadata">

**Author:** ![emeeder](https://forum.hestiacp.com/letter_avatar_proxy/v4/letter/e/a587f6/32.png) [@emeeder](https://forum.hestiacp.com/u/emeeder)\
**Post date:** [April 25, 2021, 1:46am UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326/24 "2021-04-25T01:46:10Z")

</div>

thanks Eris.

Maybe this sounds familiar to someone. After Magento installed, everything appears fine. but after approx 1-2 hrs (not sure exactly how long) the link to magento admin becomes a dead link.  
404 Not Found - “The page you requested was not found, …”  
The website front end remains fine.

Is there a timer setting that is causing this? No error message. just dead link.

---

<div class="post-metadata">

**Author:** ![eris](https://forum.hestiacp.com/user_avatar/forum.hestiacp.com/eris/32/1241_2.png) [@eris](https://forum.hestiacp.com/u/eris)\
**Post date:** [April 25, 2021, 8:29am UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326/25 "2021-04-25T08:29:16Z")

</div>

I know Magento changes admin usr to something like: admin\_randomstring

How ever I have no idea

---

<div class="post-metadata">

**Author:** ![emeeder](https://forum.hestiacp.com/letter_avatar_proxy/v4/letter/e/a587f6/32.png) [@emeeder](https://forum.hestiacp.com/u/emeeder)\
**Post date:** [April 25, 2021, 11:41pm UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326/26 "2021-04-25T23:41:00Z")

</div>

Regarding the 404 error on the admin side. It didn’t error right after installing magento. maybe 1-2 hrs later it would start with the 404 error.  
Resolved it using this:

From: [How to Fix Magento Admin 404 Error After Install - SimiCart](https://www.simicart.com/blog/magento-admin-404/)

Delete var/cache folder  
Go to your Magento 2 database and run the following SQL query:  
SELECT \* FROM core\_config\_data WHERE path = ‘web/seo/use\_rewrites’ and make it 0 (mine was set to 1)

If this looks like an unwise fix. Please let me know.  
thanks

---

<div class="post-metadata">

**Author:** ![themew](https://forum.hestiacp.com/user_avatar/forum.hestiacp.com/themew/32/1099_2.png) [@themew](https://forum.hestiacp.com/u/themew)\
**Post date:** [May 6, 2021, 3:58pm UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326/27 "2021-05-06T15:58:59Z")

</div>

> [@eris](#):
>
> We rebuild crontab -I every time Hestia updates…

@eris Does this mean we need to restart or reinstall the Magento cron when HestiaCP updates to a new version? After the last HestiaCP update, running `crontab -l` displayed nothing as the Magento user and the 3 log files in the Magento/var/log directory (cron.log , exception.log , magento.cron.log) didn’t exist.

---

<div class="post-metadata">

**Author:** ![eris](https://forum.hestiacp.com/user_avatar/forum.hestiacp.com/eris/32/1241_2.png) [@eris](https://forum.hestiacp.com/u/eris)\
**Post date:** [May 6, 2021, 6:35pm UTC](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326/28 "2021-05-06T18:35:26Z")

</div>

Just put the cronjob in the “Cron” tab via CLI command

`v-add-cron-job $user "*/5" "*" "*" "*" "*" "/usr/bin/php7.4 /home/$user/web/$domain/public_html/bin/magento cron:run"`

Or just manually.

It has been done like this in the past as it would allow in case the hell break loose and you need to restore from backup. The cronjob will also in a backup.

[Previous page](https://forum.hestiacp.com/t/install-without-nginx-goal-magento-2-4-install/3326.md?page=1)
