Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagebash
uci set lldpd.config.enable='1'
uci commit
/etc/init.d/lldpd enable
/etc/init.d/lldpd start
# Проверка на наличие соседей
lldpctl

Просмотр состояния базы данных (занятое дисковое место)

Code Block
var collectionNames = db.getCollectionNames(),
  stats = [];
collectionNames.forEach(function (n) {
  stats.push(db[n].stats());
});

for (var c in stats) {
  if (!stats[c]["ns"]) continue;
  print(stats[c]["ns"].padEnd(40) + ": " + (''+stats[c]["count"]).padEnd(12) + (stats[c]["size"] / 1073741824).toFixed(3).padStart(8) + "GB" + (stats[c]["storageSize"] / 1073741824).toFixed(3).padStart(8) + "GB");
}