executing commands through FTP session

Dears,
i want to execute unix commands through FTP session those commands like grep XXXXX file name > new file
tar new file
..... etc

Please let me know how to so

thank you

Some FTP servers support the SITE command, but that is pretty limited too. vsftpd, for example, only allows SITE CHMOD, and nothing else.

If this is unix-unix you may wish to look at Remote Shell.

how can i do the Remote Shell.