Quick installation

Last Updated: Jan 10, 2017

Environment requirement

Python SDK requires a Python-ready environment. Python versions: Version 2.5 to Version 2.7. SDK is applicable to Windows and Linux, but as Python3.0 is not fully compatible with SDK Version 2.x, SDK does not support Python3.0 or above.

After Python is installed:

  • Input python in Linux shell and press Enter to view the Python version. As shown below:
  1. Python 2.5.4 (r254:67916, Mar 10 2010, 22:43:17)
  2. [GCC 4.1.2 20080704 (Red Hat 4.1.2-46)] on linux2
  3. Type "help", "copyright", "credits" or "license" for more information.
  4. >>>
  • Input python in Windows cmd and press Enter to view the Python version. As shown below:
  1. C:\Documents and Settings\Administrator>python
  2. Python 2.7.5 (default, May 15 2013, 22:43:36) [MSC v.1500 32 bit (Intel)] on win
  3. 32
  4. Type "help", "copyright", "credits" or "license" for more information.
  5. >>>

The above shows the Python has been installed successfully.

Exception: After entering python in Windows cmd and pressing Enter, the system prompts Not an internal or external command. In such a case, check the configuration Environment variables > Path and add the Python installation path.

If the Python is not installed, you can get its installer from Python official website. The website provides detailed instructions and guidance for installing and using Python.

Installation and usage

Click here to view how to download the file. Unzip the downloaded Python SDK to the directory of the osscmd and then execute python osscmd + operation. For example, upload an object to the bucket:

  1. python osscmd put myfile.txt oss://mybucket

Please note that in osscmd, we use oss://bucket or oss://bucket/object to indicate a bucket or an object. oss:// is merely a way to indicate the resource with no other meanings.

If you need the detailed command list, enter: python osscmd.

If you need the detailed parameter list instructions, enter: python osscmd help.

Thank you! We've received your feedback.