Skip to content

Commit

Permalink
add documentation about running tool without root permissions on OpenVZ
Browse files Browse the repository at this point in the history
  • Loading branch information
vps2fast committed Jun 22, 2014
1 parent 3cabcde commit 593bdfb
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,8 @@ su fastnetmon
./fastnetmon eth0,eth1
```

Please keep in mind when run tool on OpenVZ because without root permissions tool can't get all VE ips and you should pass it explicitly.

Debugging flags.

DUMP_ALL_PACKETS will enable all packets dumping to console. It's very useful for testing tool on non standard platforms.
Expand Down
Binary file modified fastnetmon
Binary file not shown.
6 changes: 4 additions & 2 deletions fastnetmon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -608,6 +608,8 @@ vector<string> read_file_to_vector(string file_name) {
while ( getline(reading_file, line) ) {
data.push_back(line);
}
} else {
std::cout<<"Can't open file: "<<file_name<<endl;
}

return data;
Expand Down Expand Up @@ -712,8 +714,8 @@ bool load_our_networks_list() {
log_file<<"We loaded "<<network_list_from_config.size()<< " networks from whitelist file"<<endl;
}

// Whet we used unordered_map it will encrease it perfomance
//DataCounter.reserve(MAP_INITIAL_SIZE);
// When we used unordered_map it will increase it perfomance
// DataCounter.reserve(MAP_INITIAL_SIZE);

vector<string> networks_list_as_string;
// если мы на openvz ноде, то "свои" IP мы можем получить из спец-файла в /proc
Expand Down

0 comments on commit 593bdfb

Please sign in to comment.