cancel
Showing results for 
Search instead for 
Did you mean: 

Error: [RuntimeException] Could not delete /path/to/install

SOLVED

Error: [RuntimeException] Could not delete /path/to/install

Getting below error while installing magento 

 

$ composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition .
Creating a "magento/project-community-edition" project at "./"
Installing magento/project-community-edition (2.3.5-p1)
- Installing magento/project-community-edition (2.3.5-p1): Downloading (100%)
Downloading (100%)
Downloading (100%)

[RuntimeException]
Could not delete /websites/ecom/./:

2 ACCEPTED SOLUTIONS

Accepted Solutions

Re: Error: [RuntimeException] Could not delete /path/to/install

Hi @deepak_sharma28 ,

 

I understand you have tried deleting the folders as well. But if possible can you share the folder structure with us on which you are running below command or follow the below steps.

 

1. I have my apache localhost installed on below location /var/www/html/

2. I have created one new folder after html folder as magento235

/var/www/html/magwnto235/

3. I have set the 777 permission to magento235 folder.

4. I ran the command like below 

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition .

 

And it works fine for me.

 

Hope this helps you!

Problem Solved! Click Kudos & Accept as Solution!

View solution in original post

Re: Error: [RuntimeException] Could not delete /path/to/install

Hi @Nishu Jindal ,

 

Did the following steps as you advised. 

 

1. I created one new folder after html folder as magento240

    /var/www/html/magento240

 

2. I have set the 777 permission to magento240 folder.

$ sudo chmod –R 777 magento240

 

3. I ran the command like below 

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition. 

 

And I am not getting the error RuntimeException] Could not delete,

I think the issue was with permissions and this resolved it $ sudo chmod –R 777 magento240

 

But I have ran into a different problem and will create a separate ticket for the same.  

Thanks for the solution,

View solution in original post

5 REPLIES 5

Re: Error: [RuntimeException] Could not delete /path/to/install

Hi @deepak_sharma28,

Can you cross check once your directory in which you are trying to install the magento is completely empty or not. Make sure there is no .git folder.

 

If still you are facing issue,try to change the command provide the path of folder instead of .

Like

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition /websites/ecom/

 

Hope this helps you!

Problem Solved! Click Kudos & Accept as Solution!

 

Re: Error: [RuntimeException] Could not delete /path/to/install

Hi @Nishu Jindal 

As advised did the below steps.

 

1) I deleted both the folders "websites" and "ecom" and recreated the same.

  Same Error. 

 

2) tried to change the command provide the path of folder instead of .

Like below

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition /websites/ecom/

Same Error.

 

Thanks

Re: Error: [RuntimeException] Could not delete /path/to/install

Hi @deepak_sharma28 ,

 

I understand you have tried deleting the folders as well. But if possible can you share the folder structure with us on which you are running below command or follow the below steps.

 

1. I have my apache localhost installed on below location /var/www/html/

2. I have created one new folder after html folder as magento235

/var/www/html/magwnto235/

3. I have set the 777 permission to magento235 folder.

4. I ran the command like below 

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition .

 

And it works fine for me.

 

Hope this helps you!

Problem Solved! Click Kudos & Accept as Solution!

Re: Error: [RuntimeException] Could not delete /path/to/install

Hi @Nishu Jindal ,

 

Did the following steps as you advised. 

 

1. I created one new folder after html folder as magento240

    /var/www/html/magento240

 

2. I have set the 777 permission to magento240 folder.

$ sudo chmod –R 777 magento240

 

3. I ran the command like below 

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition. 

 

And I am not getting the error RuntimeException] Could not delete,

I think the issue was with permissions and this resolved it $ sudo chmod –R 777 magento240

 

But I have ran into a different problem and will create a separate ticket for the same.  

Thanks for the solution,

Re: Error: [RuntimeException] Could not delete /path/to/install

It happened once to me and it turns out that I was hitting composer's timeout.

You could take the following measures to gain some speed:

  1. Increase composer process-timeout (default 300) (not really needed if the following settings will help you gain speed, but can't hurt)
  2. Set dist as preferred install type.
  3. Enable https protocol for github, which is faster.

~/.composer/config.json

{
    "config": {
        "process-timeout":      600,
        "preferred-install":    "dist",
        "github-protocols":     ["https"]
    }
}

If you still have problems after that, you can also clear composer's cache:

rm -rf ~/.composer/cache