Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Can someone tell me how to use magento ssh&shell;command? 
 
ctrol
Member
 
Total Posts:  43
Joined:  2010-10-22
 

I have tried many times intend to using magento ssh & shell command, but never succeed!
I am hosted on Godaddy,and i have modified \"mage\" file in root directory:
# REPLACE with your PHP5 binary path (example: /usr/local/php5/bin/php )
MAGE_PHP_BIN=\"/usr/local/php5/bin/php\"

Then I logined SSH:
-bash-3.2$ ./mage install http://connect20.magentocommerce.com/community Mage_All_Latest --force
Error like this:-bash: ./mage: No such file or directory
Then I run shell command:
-bash-3.2$ php -f indexer.php—help
<br />
<b>Parse error</b>:  syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION
or T_FUNCTION or T_VAR or \’}\’ in <b>/home/content/85/858622/html/shell/indexer
.php</b> on line <b>43</b><br />
-bash-3.2$ php -f indexer.php—[help]
<br />
<b>Parse error</b>:  syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION
or T_FUNCTION or T_VAR or \’}\’ in <b>/home/content/85/858622/html/shell/indexer
.php</b> on line <b>43</b><br />

I am so confused,and hope someone will bring me out this trouble.
I just want to make a compiliance via shell or SSH

 
Magento Community Magento Community
Magento Community
Magento Community
 
magentosuccess
Jr. Member
 
Total Posts:  18
Joined:  2011-10-26
 

Well it depends if you have a zip file or a rar file...I prefer a rar file, may I suggest unzipping the file and making it an .rar file.

I also prefer using ssh cmds to upload magento than rather uploading each file individually…

To Unrar a file use the following code

rar x /home/loginname/domain/magento.rar /pathtoputitin

Make sure there a space after .rar

Example: You want to install it on magento.com

The user you have setup for that domain for FTP/SHELL access is called “coolkicks”

so your code should be:

rar x /home/coolkicks/magento.com/magento.rar /home/coolkicks/magento.com/

The code above will install it directly into the home directory of your domain...but if your home address is “homedir”

Then the code must be

rar x /home/coolkicks/magento.com/magento.rar /home/coolkicks/magento.com/

for sub-directory installs:

rar x /home/coolkicks/magento.com/magento.rar /home/coolkicks/magento.com/testfolder

Let me know if this helps!

 
Magento Community Magento Community
Magento Community
Magento Community
 
brendanb
Mentor
 
Total Posts:  1093
Joined:  2008-07-16
London, United Kingdom
 

Hi,

Have a look at the wiki\’s. There are details on using ssh to setup a magento store

http://www.magentocommerce.com/wiki/groups/227/upgrading_magento_via_ssh

this thread might also be of help

http://www.magentocommerce.com/boards/viewthread/200/P15/

brendan

 
Magento Community Magento Community
Magento Community
Magento Community
 
ctrol
Member
 
Total Posts:  43
Joined:  2010-10-22
 

I was not intend to install Magento via SSH, I am trying to reindex magento via SSH,but always see this error:
<b>Parse error</b>:  syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or ‘}’ in <b>/html/shell/indexer.php</b> on line <b>43</b><br />
I don’t know where I am wrong.
Can some one tell me ?

 
Magento Community Magento Community
Magento Community
Magento Community
 
brendanb
Mentor
 
Total Posts:  1093
Joined:  2008-07-16
London, United Kingdom
 

can you post a screen print

thanks

 
Magento Community Magento Community
Magento Community
Magento Community
 
cactuscamiseta
Jr. Member
 
Total Posts:  10
Joined:  2011-04-06
 
ctrol - 02 April 2012 06:30 AM

I was not intend to install Magento via SSH, I am trying to reindex magento via SSH,but always see this error:
<b>Parse error</b>:  syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or ‘}’ in <b>/html/shell/indexer.php</b> on line <b>43</b><br />
I don’t know where I am wrong.
Can some one tell me ?

Tha same here. Any ideas about how to solve this? I get this message when I try to run the ./shell php indexer.php reindexall command.

Thanks in advanced.

Cheers!

 
Magento Community Magento Community
Magento Community
Magento Community
 
limex
Jr. Member
 
Avatar
Total Posts:  10
Joined:  2012-03-18
 

I also got this unexpected T_STRING error.
The reason was that the command php used version 4 of php.
So: When using

php5 -f indexer.php info
everything worked.

Maybe your provider has the same setup.
Hope it helps.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top