From aea446f3b59c84cf9e5d8b08e3d8d0b181be09b4 Mon Sep 17 00:00:00 2001 From: Michael Larson Date: Thu, 20 Mar 2008 14:17:46 -0700 Subject: up proc limit for rmem_max to support zebra netlink buffer size increase. --- scripts/rl-system.init | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts') diff --git a/scripts/rl-system.init b/scripts/rl-system.init index 5eae0ae4..a70c0a46 100755 --- a/scripts/rl-system.init +++ b/scripts/rl-system.init @@ -91,7 +91,7 @@ proc_flags () echo 1 > /proc/sys/net/ipv4/conf/all/promote_secondaries # set maximum rmem_max to accomodate netlink buffers - echo 223232 > /proc/sys/net/core/rmem_max + echo 1048576 > /proc/sys/net/core/rmem_max } ## Update the version information -- cgit v1.2.3 From 2d13f356b2fdfd4da1ce4e288e97c67f0ece1dbf Mon Sep 17 00:00:00 2001 From: Robert Bays Date: Fri, 21 Mar 2008 13:31:34 -0700 Subject: fix bug 3039 --- scripts/install-system | 48 +++++++++++++++++++++++------------------------- 1 file changed, 23 insertions(+), 25 deletions(-) (limited to 'scripts') diff --git a/scripts/install-system b/scripts/install-system index eb4c7bb3..8d119087 100755 --- a/scripts/install-system +++ b/scripts/install-system @@ -281,35 +281,33 @@ check_config_partition() { mkdir -p /mnt/tmp output=$(mount /dev/$lpart /mnt/tmp 2>&1) if [ $? != 0 ]; then - echo -e "Cannot mount /dev/$lpart"."\nPlease see $INSTALL_LOG for more details.\nExiting.." echo -e "Cannot mount /dev/$lpart"."\nmount /dev/$ldrive$part /mnt/tmp\nExiting..." >> $INSTALL_LOG echo "$output" >> $INSTALL_LOG - exit 1 - fi - - # Look to see if there is a config partition there - if [ -f /mnt/tmp/opt/vyatta/etc/config/.vyatta_config ] || [ -f /mnt/tmp/.vyatta_config ]; then - response='' - while [ -z "$response" ] - do - echo "/dev/$lpart has an old configuration directory!" - echo -ne "Would you like me to save the data on it\nbefore I delete it? (Yes/No) [Yes]: " - response=$(get_response "Yes" "Yes No Y N") - if [ "$response" == "yes" ] || [ "$response" == "y" ]; then - mkdir -p /mnt/config - if [ -d /mnt/tmp/opt/vyatta/etc/config ]; then - output=$(cp -pR /mnt/tmp/opt/vyatta/etc/config/* /mnt/config) - else - output=$(cp -pR /mnt/tmp/* /mnt/config) - fi - if [ -n "$output" ]; then - echo -e "Warning: error in copying the old config partition.\nSee $INSTALL_LOG for more details." - echo -e "Warning: error in copying the old config partition.\ncp -pR /mnt/tmp/* /mnt/config\n$output\n" >> $INSTALL_LOG + else + # Look to see if there is a config partition there + if [ -f /mnt/tmp/opt/vyatta/etc/config/.vyatta_config ] || [ -f /mnt/tmp/.vyatta_config ]; then + response='' + while [ -z "$response" ] + do + echo "/dev/$lpart has an old configuration directory!" + echo -ne "Would you like me to save the data on it\nbefore I delete it? (Yes/No) [Yes]: " + response=$(get_response "Yes" "Yes No Y N") + if [ "$response" == "yes" ] || [ "$response" == "y" ]; then + mkdir -p /mnt/config + if [ -d /mnt/tmp/opt/vyatta/etc/config ]; then + output=$(cp -pR /mnt/tmp/opt/vyatta/etc/config/* /mnt/config) + else + output=$(cp -pR /mnt/tmp/* /mnt/config) + fi + if [ -n "$output" ]; then + echo -e "Warning: error in copying the old config partition.\nSee $INSTALL_LOG for more details." + echo -e "Warning: error in copying the old config partition.\ncp -pR /mnt/tmp/* /mnt/config\n$output\n" >> $INSTALL_LOG + fi fi - fi - done + done + fi + umount /mnt/tmp fi - umount /mnt/tmp } # Delete all existing partitions for an automated install -- cgit v1.2.3 From f279d69e1d3952de1231ecf56d6ebb3023b96645 Mon Sep 17 00:00:00 2001 From: Mohit Mehta Date: Fri, 21 Mar 2008 17:02:29 -0700 Subject: Fix Bug 3027 Unable to configure SNMP community client address - added the following commands: - set protocols snmp community client - set protocols snmp community network --- scripts/snmp/vyatta-snmp.pl | 37 ++++++++++++++++++---- .../snmp/community/node.tag/client/node.def | 3 ++ .../snmp/community/node.tag/network/node.def | 4 +++ 3 files changed, 38 insertions(+), 6 deletions(-) create mode 100644 templates/protocols/snmp/community/node.tag/client/node.def create mode 100644 templates/protocols/snmp/community/node.tag/network/node.def (limited to 'scripts') diff --git a/scripts/snmp/vyatta-snmp.pl b/scripts/snmp/vyatta-snmp.pl index f12bcc45..0301a041 100644 --- a/scripts/snmp/vyatta-snmp.pl +++ b/scripts/snmp/vyatta-snmp.pl @@ -74,12 +74,37 @@ sub snmp_get_values { my @communities = $config->listNodes(); foreach my $community (@communities) { - my $authorization = $config->returnValue("$community authorization"); - if (defined $authorization and $authorization eq "rw") { - $output .= "rwcommunity $community\n"; - } else { - $output .= "rocommunity $community\n"; - } + my $authorization = $config->returnValue("$community authorization"); + my @clients = $config->returnValues("$community client"); + my @networks = $config->returnValues("$community network"); + + if (scalar(@clients) == 0 and scalar(@networks) == 0){ + if (defined $authorization and $authorization eq "rw") { + $output .= "rwcommunity $community\n"; + } else { + $output .= "rocommunity $community\n"; + } + } else { + if (scalar(@clients) != 0){ + foreach my $client (@clients){ + if (defined $authorization and $authorization eq "rw") { + $output .= "rwcommunity $community $client\n"; + } else { + $output .= "rocommunity $community $client\n"; + } + } + } + if (scalar(@networks) != 0){ + foreach my $network (@networks){ + if (defined $authorization and $authorization eq "rw") { + $output .= "rwcommunity $community $network\n"; + } else { + $output .= "rocommunity $community $network\n"; + } + + } + } + } } $config->setLevel("protocols snmp"); diff --git a/templates/protocols/snmp/community/node.tag/client/node.def b/templates/protocols/snmp/community/node.tag/client/node.def new file mode 100644 index 00000000..134698ef --- /dev/null +++ b/templates/protocols/snmp/community/node.tag/client/node.def @@ -0,0 +1,3 @@ +multi: +type: ipv4 +help: IP address of SNMP client allowed to contact system diff --git a/templates/protocols/snmp/community/node.tag/network/node.def b/templates/protocols/snmp/community/node.tag/network/node.def new file mode 100644 index 00000000..1afdb2a1 --- /dev/null +++ b/templates/protocols/snmp/community/node.tag/network/node.def @@ -0,0 +1,4 @@ +multi: +type: ipv4net +help: Subnet of SNMP client(s) allowed to contact system +syntax:expression: exec "/opt/vyatta/sbin/vyatta_quagga_utils.pl --check-prefix-boundry $VAR(@)" -- cgit v1.2.3