Skip to main content

No project description provided

Project description

code:: python

from Azog.base.exception import HostClientException from Azog import Host

hosts = [

{‘Address’: ‘192.223.42.25’, ‘Port’: 22, ‘User’: ‘root’, ‘Password’: ‘123456’},

]

if __name__ == ‘__main__’:

for i in hosts:
try:

h = Host(i) # system print(h.sys_info.get_uptime()) print(h.sys_info.get_load()) print(h.sys_info.get_kernel()) print(h.sys_info.get_release()) print(h.sys_info.get_architecture()) # cpu print(h.cpu_info.get_cpu_name()) print(h.cpu_info.get_cpu_cores()) print(h.cpu_info.get_cpu_freq()) print(h.cpu_info.get_cpu_core_cache()) # ram print(h.ram_info.get_total_ram()) print(h.ram_info.get_use_ram()) print(h.ram_info.get_buff_ram()) print(h.ram_info.get_total_swap()) print(h.ram_info.get_use_swap()) # disk print(h.disk_info.get_total_disk()) print(h.disk_info.get_use_disk())

# sftp h.sftp_get(‘/root/111/2131’, ‘1’) h.sftp_put(‘demo.py’, ‘/root/111/demo.py’)

print(‘*’ * 50)

except HostClientException as e:

print(e.code, e.message)

except Exception as e:

print(e)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Azog-0.2.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

Azog-0.2-py3-none-any.whl (7.5 kB view details)

Uploaded Python 3

File details

Details for the file Azog-0.2.tar.gz.

File metadata

  • Download URL: Azog-0.2.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.12

File hashes

Hashes for Azog-0.2.tar.gz
Algorithm Hash digest
SHA256 e4dc8c558edf9afeff7be15763d6867d90fb0c83d47ce112e2f46c2342714367
MD5 c087d27bb5b6fd291e0b0f7ce0bba1b6
BLAKE2b-256 0e3c5920fda5dfef5526f6b5db207490da83a35458f36dbb4139834a9073c479

See more details on using hashes here.

File details

Details for the file Azog-0.2-py3-none-any.whl.

File metadata

  • Download URL: Azog-0.2-py3-none-any.whl
  • Upload date:
  • Size: 7.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.12

File hashes

Hashes for Azog-0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 514d168a5150104d790c817299e38f60e6b845e96f42fc9374c8e2920c10cbac
MD5 1ffe6dde43a5eddf77105b68e1af5c8c
BLAKE2b-256 c96b09509bb6bd7b9c81e65c33c6d5de8f44212acad42585a5087b8a9a721851

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page