Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [command-line]

Denotes questions related to command line.

1
vote
1answer
75 views

Magento 2 Command Line Issue

Instead of entering each command individually is there a single commande that I can enter to deploy content and to also clear the appropriate folders?
1
vote
2answers
347 views

Magento Commands - Segmentation Fault (Core Dumped)

I receive the following error when running any of the magento commands in CL? Any ideas on how to resolve? Segmentation Fault (Core Dumped) Thanks
2
votes
2answers
2k views

Magento 2 auto install shell script

I am wondering is it possible to install Magento 2 with a shell script? Like we run shell script and Magento 2 will be installed automatically? Just like softaculous on cpanel ? Any help will be ...
0
votes
1answer
2k views

Anyone know commands for Magento 1

Does anyone know how the following commands would be translated to Magento 1? sudo rm -rf var/cache var/generation var/di sudo php bin/magento setup:upgrade sudo chown -R bitnami:bitnami . sudo php ...
15
votes
6answers
4k views

Magento 2: When should I run which commands?

I have been working with Magento 2 for 2 months now. I realized that I am using bin/magento setup:upgrade way too much. I think I do not know when I have to run that command. Here are the situations ...
0
votes
1answer
297 views

Permission denied when try any command in magento 2.1

When I try to set permissions to folder and files using command like find . -type f -exec chmod 644 {} \; // 644 permission for files find . -type d -exec chmod 755 {} \; ...
0
votes
3answers
547 views

Adding products using a custom CLI command

I've written a custom CLI command to import products from an external database into Magento, however whenever I try to save the product, an Exception is thrown. [Magento\Framework\Exception\...
0
votes
1answer
58 views

Can not export database by command line window

I exported database by command line. I got this error: gzip is not recognized as an internal or external command, operable program or batch file. How to fix it ?
1
vote
2answers
1k views

Error display on Setup upgrade command

I am facing an error while running command bin/php magento setup:upgrade. It return the error shown below. [Magento\Setup\Exception] Database ...
2
votes
2answers
288 views

Using Command Lines Magento 2

Dear Magento specialists, I always had Magento 1 running. However for my new webshop I like to run Magento 2. I have installed Magento 2 using Installatron. I extracted theme files in the root ...
1
vote
1answer
269 views

Find any file using Main.css using Grep Commandline

I'm looking to find a file that contains main.css using grep command line on mac OS/Linux. How do I go about searching a directory using grep for a certain file?
3
votes
1answer
898 views

Magento 1.9.3 Command Line Not Available

I have a quick question regarding the command line tool seen in Magento 2. I've been using it and it's amazing cool. However now I'm working on an older version of Magento 1.9.3 and I see there isn't ...
5
votes
2answers
2k views

Command line error stock magento

I get this error after install when trying to clear var/ generation, and static content deploy via command line. [Exception] Warning: Invalid argument supplied for foreach() in /vendor/magento/...
1
vote
1answer
514 views

Command line not accepting commands

When I run any M2 command line scripts I get the follow error message: Command line user does not have read and write permissions on var/generation directory. Please address this issue before using ...
1
vote
1answer
687 views

Magento change index mode using command line

I need to change index mode for a particular single index using command line. I have followed this link it allows me to re-index data but when I try to change mode of index, either I get list of ...
0
votes
1answer
17 views

Magento 2 : Custom Module Only Working One Time

I made a custom module to add an extra field into a Magento 2 table. It worked fine when I run php bin/magento setup:upgrade The extra field is added into table. I deleted field, and tried ...
4
votes
1answer
2k views

How can i run system->import/export->export by Command ssh

I get no valid data send error during product export via system->import/export->export. Actually this because of time out error. How can run this export by command ssh.
1
vote
2answers
407 views

activate full page caching using Varnish from command line

Is there a way to activate the Varnish use using the command line, not the admin interface? In the bin/magento comand line tool there are options for cache but nothing specific for Varnish. I am ...
1
vote
1answer
447 views

Magento 2: Compile-Multi-Tenant “Not Defined”

My Module reject from Marketplace QA testing. The error they gave was: [ReflectionException] Class \Fanplayr\SmartAndTargeted\Controller\Index\Index does not exist They also let me know test command ...
0
votes
1answer
671 views

Why do CLI commands return no errors/exceptions?

Problem: I'm writing a custom module, and everything is output just fine when there are no errors/exceptions. But as soon as I experience an error, nothing is displayed in the command line (using ...
16
votes
4answers
34k views

How to reindex Magento by using command line

How can I reindex magento using by command line. Kindly provide steps for the same.
0
votes
1answer
659 views

Magento 2 console command run from an adminhtml page generates an error — why?

I'm trying to run a Magento 2 console command from within an adminhtml Controller in a custom module. (The module itself is configured correctly, enabled, and running just fine with no errors.) I ...
0
votes
1answer
145 views

Custom commandline script: Area code is not set

I've got a module that was written by a 3rd party developer and unfortunately, they've fallen off of the face of the earth. 99% of it works as required, except one issue. The extension was built to ...
3
votes
1answer
788 views

Console command waiting for input from user

It is possible in PHP to create console command waiting for an input from user like this or like this. Is there any 'magento-way' or above approaches can be used?
1
vote
3answers
1k views

Magento Command Line Global Commands

I am in a Digital Ocean Ubuntu droplet trying to toggle development mode in my Magento installation so that I can develop a theme. My problem is I can't figure out how to run magento deploy:mode:set ...
11
votes
2answers
2k views

Magento2 - Command-Line - Sending Email Using Block Templates - Error: Missing required argument $debugHintsPath

When attempting to send emails in Magento 2 from command-line, I encountered the exception below. While using the very same class to send emails from an frontend or backend controller was working ...
0
votes
1answer
2k views

Updating via SSH: Magento CE 2.1.2 to 2.1.3

I would like to update my Magento 2.1.2 version to the new Magento 2.1.3 via SSH. I have established a connection with my server, but am not sure how to continue. The internet provides me commands ...
1
vote
2answers
3k views

Magento 2 How to Create a Custom Console Command

Is it possible to create a new Magento command for example to delete the generation folder?
11
votes
3answers
4k views

magento 2: 'i18n:collect-phrases' command creates different csv files

php bin\magento i18n:collect-phrases -o "C:\xampp\htdocs\magento\app\design\i18n\xx_YY.csv" -m collects all phrases in the magento application and outputs a csv file with 4 columns: php bin\magento ...
0
votes
1answer
591 views

run php shell commands

I put my Magento website in a not dedicated server. So, everytime I want to run some php shell commands I have to write an email to my WebHosting tutor and tell him wich commands he has to execute. ...
0
votes
1answer
887 views

M2 - Cannot change deploy mode to Production

I am trying to set the deploy mode on an M2 instance to Production from Developer. On my local environment however I keep getting the error message: Command returned non-zero exit code: '/...
3
votes
3answers
9k views

Magento 2 - setup:install & setup:upgrade

I have updated the code in my custom module and run setup:install already. Do I still need to run setup:upgrade?
5
votes
2answers
1k views

Magento 2: Nginx pub/static not autogenerating, only works with command line static-content:deploy

I have tried many of the solutions from: Local installation of Magento 2 doest not generate files in the pub/static folder and similar posts: I am in developer mode (verified in command line, and I ...
2
votes
0answers
166 views

magento setup:upgrade enables module

I've just created a Magento2 module, here is the module.xml <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:...
18
votes
5answers
17k views

Magento 2: What is difference between Cache Clean & Cache Flush?

In Magento 2 we have 2 commands php bin/magento cache:flush php bin/magento cache:clean What's the exact difference between them? I'm generally using cache:flush. I never used cache:clean. So, ...
2
votes
0answers
48 views

Deploy Sample Data Content to app/code folder instead of vendor

I can deploy sample data to vendor folder with with the command bin/magento sampledata:deploy in Magento 2 however I want to edit this command to deploy sample data to app/code/magento folder instead ...
0
votes
1answer
274 views

how to use command line in magento 2.1?

I have tried to run the command line script in a linux VPS with PuTTy and get this error: Magento supports PHP 5.6, 7.0.2, and 7.0.6 or later. Please read http://devdocs.magento.com/guides/v1.0/...
2
votes
2answers
616 views

What are basic steps for installing a third party theme in Magento 2?

[ Asking for the proper sequence and the basic steps ] Hello, I am beginner to Magento 2, and its folder structure. I am trying to install a theme in M2, and has finally installed. But to achieved ...
0
votes
2answers
5k views

Execute magento commands in php shell without SSH

My webserver host does not provide access to SSH. I want to run commands like: php bin/magento setup:static-content:deploy I have tried to do this in the shell terminal using: - phpFileManager - ...
1
vote
0answers
57 views

n98-magerun doesn't throw errors?

I am working on a magerun command, but it seems that errors are not triggered. E.g. protected function execute(InputInterface $input, OutputInterface $output) { $this->detetMagento($output); } ...
5
votes
2answers
4k views

How to install module magento 2 don't need run command line bin/magento setup:upgrade

I need to install module pf magento 2 in hosting. I'm trying to connect host with port 21 using putty but not success. I need one other way, please help me.
1
vote
2answers
997 views

Magento file system owner Ubuntu

I am really really new to Magento 2 so forgive my lack of knowledge. I am reading the Magento documentation and I keep seeing Magento file system owner. E.g. sudo -u Magento_file_system_owner ...
0
votes
2answers
100 views

Install module in magento 2 on hosting

pls help me, install module in hosting, I upload module on hosting using filezilla but module cant not run, because i dont know run cmd bin/magento setup:upgrade on host server. My english isn't good,...
5
votes
5answers
5k views

Magento 2 var/di folder is missing

There is no di folder generated in var directory. I am getting please re-run compile command. Why we need this di directory?
1
vote
2answers
298 views

Compile command not running in staging environment

When I run $ php bin/magento setup:di:compile command on local machine, it recompiles dependencies right away. When I do the same on staging server, it displays a message: DI configuration must be ...
3
votes
5answers
2k views

enable multiple modules for same namespace

I am installing a few modules one by one into my magento 2 application. Can we enable all modules in the same namespace with one command? Right now I am using: php bin/magento module:enable ...
1
vote
2answers
4k views

How to set the locale (en_US") of Magento2 (I/F Locale) by using command line

I have installed magento 2.0.7 with CentoOS 7 / Apache 2.4.6 / PHP 7 / MariaDB 10. After applying the Japanese locale to "Interface Locale" under Account Setting (refer the link below), I get "HTTP ...
1
vote
1answer
633 views

Magento Code Migration Tool - Installation issue

i'm currently following the steps in https://github.com/magento/code-migration to install the Code Migration Tool (not data migrate) to my localhost. i am facing a problem at the Installation ...
2
votes
1answer
529 views

Magento 2 Custom command Area Code note set exception

I have created a command for my module which calls a class Model/Importer from https://github.com/firegento/FireGento_FastSimpleImport2 extension. but i think it requires admin session. I have tried ...
0
votes
1answer
97 views

Get custom command line parameter during module install() process

Is there a way to access command line parameters from inside the magento installer routines? I'm attempting to set up a few custom variables representing our current environment (dev / test / prod) ...