Path: csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail From: Joel Goldstick Newsgroups: comp.lang.python Subject: Re: snmpset Date: Fri, 5 Feb 2016 12:12:58 -0500 Lines: 36 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: news.uni-berlin.de aK2Kr87XlpqCXfmIy02j9wDQo/6v0A3WFI/zSfVB7Isw== Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.004 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'url:sourceforge': 0.03; 'received:209.85.223': 0.03; 'api': 0.09; 'behavior,': 0.09; 'subclass': 0.09; 'url:)': 0.14; '2016': 0.16; 'pythonic': 0.16; 'received:io': 0.16; 'received:psf.io': 0.16; 'wrote:': 0.16; '>': 0.18; 'email addr:gmail.com>': 0.18; 'python?': 0.18; 'to:name:python-list@python.org': 0.20; 'am,': 0.23; 'feb': 0.23; 'header:In-Reply-To:1': 0.24; 'example': 0.26; 'equivalent': 0.27; 'fri,': 0.27; 'message-id:@mail.gmail.com': 0.27; 'url:mailman': 0.30; 'url:python': 0.33; 'url:listinfo': 0.34; 'received:google.com': 0.35; 'skip:. 20': 0.35; 'something': 0.35; 'but': 0.36; 'should': 0.36; 'url:org': 0.36; 'received:209.85': 0.36; 'to:addr:python-list': 0.36; 'subject:: ': 0.37; 'received:209': 0.38; 'test': 0.39; 'url:mail': 0.40; 'to:addr:python.org': 0.40; 'success': 0.62; 'effective.': 0.66; 'joel': 0.91; 'ware': 0.91 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=vv5F6P4mFKLnuVs6NRwdE0lJulK3rsSHdCRv+k5ThlQ=; b=0BDqStW6dh0abOK/V5rse575ZZBhY9UrQboOe180SJisPUR8VvrquiuO6WfsL1xGvq aWNTeLC+lmMOY+QwuB+3kAeewd0RBaFts+0xPTtYvWW+3DRwvJ5IjybLBsL/mD6hHfO9 hjfoULTYmS/y07F/hPM+Womgs3vnUIrSt4vI+jne7Xw8BuMwClOQYQDTvMI0CP9F2Asw mGcnAalPR65hI6GCLf5h5Ft0784uKBNqom0dTL9/d4h8At6IU6+oad0ivyxmTnwBFM37 TBUm/hyGuWY/v+cziockMOa8narqsg7Ov/xRztEozpVL5ktwuiI6DIexXLAKGD/jdVn9 nBmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=vv5F6P4mFKLnuVs6NRwdE0lJulK3rsSHdCRv+k5ThlQ=; b=JjOi0xlUbnFrEN4CQ+sIAjs40PI+jML9WSBIikBLaz113kv247onFgvxCgDZZ5aujb ei4TaQK/nK5vaFuOW+FP5LspoFXTOrJJttb1CtvCCBBkw4lSG9hgpo3G94d/IfYsZgCd SYYxlr4xRU8KK0ua0KKuXEHof1X9TV8mGAbFEmedWra9hgh8SOfxa6dYDpSRtywvlKP9 nfNmsfF/1huHadQVf+CAdfA0wu/spqW6Bu5Ei9dYS4rFzZxv3GVl1LEgMy0kc4n1Dkw6 E0c/DbH6w4nH5vnw68SuUfbsmMGb4fsDGehDtQoehO1qvycGBOMtJ8LxC3kh5xXFe8pn KEsw== X-Gm-Message-State: AG10YOTFxAh6336e4BxgBzR2kHalFpwVxTtsWPNvltnWOsek2h4yyekrErJb53TPa19vtDiPJ+LF8zCFClDIrw== X-Received: by 10.107.62.5 with SMTP id l5mr16214286ioa.180.1454692378343; Fri, 05 Feb 2016 09:12:58 -0800 (PST) In-Reply-To: X-Content-Filtered-By: Mailman/MimeDel 2.1.21rc2 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.21rc2 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Xref: csiph.com comp.lang.python:102531 On Fri, Feb 5, 2016 at 11:10 AM, Zachary Ware wrote: > On Fri, Feb 5, 2016 at 9:16 AM, Matt wrote: > > How do I do the equivalent of this in Python? > > > > snmpset -v 2c -c $community $ip .1.3.1.1.4.1.1.1.1.1.1.1.0 s test > > > > and > > > > snmpset -v 2c -c $community $ip .1.3.1.1.4.1.1.1.1.1.1.1.0 i 123 > > > > and > > > > snmpbulkget -v2c -c $community -m ALL $ip .1.3.1.1.4.1.1.1.1.1.1.1.1 > > > > and > > > > snmpget -v2c -c $community -m ALL $ip .1.3.1.1.4.1.1.1.1.1.1.1.2 > > I have had success with pysnmp (http://pysnmp.sourceforge.net/). It > is far from a shining example of a Pythonic API and I don't envy you > if you should need to subclass something to change its behavior, but > it is effective. > > -- > Zach > -- > https://mail.python.org/mailman/listinfo/python-list > That page 404s for me -- Joel Goldstick http://joelgoldstick.com/stats/birthdays