Exemplo n.º 1
0
def database_add():
#[JPC] refactor routine
    ed = EADatabase()
    ed.simple_db_test()

    snapshot = RancidSnapshotManager()

    dev_snap = snapshot.get_snapshot_single(sys.argv[2])
    ed.insert_dev_file(last_id, dev_snap, sys.argv[3])
Exemplo n.º 2
0
def database_add():
    #[JPC] refactor routine
    ed = EADatabase()
    ed.simple_db_test()

    snapshot = RancidSnapshotManager()

    dev_snap = snapshot.get_snapshot_single(sys.argv[2])
    ed.insert_dev_file(last_id, dev_snap, sys.argv[3])
Exemplo n.º 3
0
def file_add():
#File add
    ea_write = open('snap.dat','a')
    em = EAMeasurement()
#ed.simple_db_test()

    snapshot = RancidSnapshotManager("")
    dev_snap = snapshot.get_snapshot_single(sys.argv[2])
    em.write_measurement(ea_write, dev_snap, sys.argv[3])
    ea_write.close()
Exemplo n.º 4
0
def file_add():
    #File add
    ea_write = open('snap.dat', 'a')
    em = EAMeasurement()
    #ed.simple_db_test()

    snapshot = RancidSnapshotManager("")
    dev_snap = snapshot.get_snapshot_single(sys.argv[2])
    em.write_measurement(ea_write, dev_snap, sys.argv[3])
    ea_write.close()
Exemplo n.º 5
0
#!/usr/bin/env python

import sys

from EnergyAuditProfile import EnergyAuditProfile
from SnapshotManager import RancidSnapshotManager



profile = EnergyAuditProfile()
profile.open_profile()
snapshots = RancidSnapshotManager(profile)

#This is for normal rancid
if len(sys.argv) == 1:
    snapshots.take_dev_snapshot()
    snapshots.run_audit_file("snap.dat")
else:
    print "DOIT Snapshot"
    snapshots.take_doit_snapshot()
    print "snapshots complete"
    snapshots.run_audit_file("snap.dat")
Exemplo n.º 6
0
#!/usr/bin/env python

import sys

from EnergyAuditProfile import EnergyAuditProfile
from SnapshotManager import RancidSnapshotManager

profile = EnergyAuditProfile()
profile.open_profile()
snapshots = RancidSnapshotManager(profile)

#This is for normal rancid
if len(sys.argv) == 1:
    snapshots.take_dev_snapshot()
    snapshots.run_audit_file("snap.dat")
else:
    print "DOIT Snapshot"
    snapshots.take_doit_snapshot()
    print "snapshots complete"
    snapshots.run_audit_file("snap.dat")