Merge remote-tracking branch 'refs/remotes/origin/main'
This commit is contained in:
commit
bf96d7cb44
@ -138,4 +138,15 @@ set system login user admin authentication public-keys jafner425@gmail.com key $
|
||||
To get a monitoring panel of bandwidth usage listed by connection on the internet, use `sudo iftop -i pppoe1`.
|
||||
To instead get usage listed by connection on LAN, use `sudo iftop -p -i eth6`
|
||||
|
||||
[`iftop` docs](https://linux.die.net/man/8/iftop). Use [`pcap-filter'](https://www.tcpdump.org/manpages/pcap-filter.7.html) syntax for filtering with the `-f` flag.
|
||||
[`iftop` docs](https://linux.die.net/man/8/iftop). Use [`pcap-filter'](https://www.tcpdump.org/manpages/pcap-filter.7.html) syntax for filtering with the `-f` flag.
|
||||
|
||||
# Setting up the Aruba S2500-48P
|
||||
Followed the instructions given in [this video](https://www.youtube.com/watch?v=HegeBkglsec)
|
||||
|
||||
1. Reset to factory settings.
|
||||
2. Basic configuration (using static IP 192.168.1.9).
|
||||
3. Flashed new firmware image (7.4.0.7, built 2021_07_07) to default boot partition.
|
||||
4. Deleted stacking interfaces for 3rd and 4th SFP+ ports.
|
||||
5. Flashed new firmware image (7.4.0.7, built 2021_07_07) to backup boot partition.
|
||||
|
||||
Additional reference: https://forums.serverbuilds.net/t/official-aruba-s2500-managed-ethernet-switch-poe-10gsfp/5038
|
@ -1,26 +1,23 @@
|
||||
#!/bin/vbash
|
||||
source /opt/vyatta/etc/functions/script-template
|
||||
|
||||
# create copies of config for modification and backup
|
||||
cp /config/config.boot /config/config.new
|
||||
cp /config/config.boot /config/backups/config.bk-$(date +%Y-%m-%d)
|
||||
# get current public IP
|
||||
NEW_IP=$(show interfaces pppoe pppoe1 | grep "inet\s" | cut -d ' ' -f 6)
|
||||
# get old public IP
|
||||
OLD_IP=$(show nat destination rules | grep 1100 | head -1 | tr -s ' ' | cut -d' ' -f 3)
|
||||
|
||||
|
||||
show configuration commands | grep $OLD_IP | sed --expression="s/$OLD_IP/$NEW_IP/" > ipupdate.tmp
|
||||
|
||||
# switch mode to config
|
||||
configure
|
||||
|
||||
# get current public IP
|
||||
NEW_IP=$(run show interfaces pppoe pppoe1 | grep "inet\s" | cut -d ' ' -f 6)
|
||||
# get old public IP
|
||||
OLD_IP=$(run show nat destination rules | grep 1100 | head -1 | tr -s ' ' | cut -d' ' -f 3)
|
||||
source ipupdate.tmp
|
||||
|
||||
# edit the config.new file
|
||||
sed -i "s/$OLD_IP/$NEW_IP/" /config/config.new
|
||||
|
||||
# apply the new config
|
||||
load /config/config.new
|
||||
{ # try commit, save, exit
|
||||
commit && save && exit
|
||||
} || { # catch, exit discard and create a very basic error file
|
||||
exit discard
|
||||
echo "Script failed. Write some real error handling."
|
||||
}
|
||||
|
||||
rm ipupdate.tmp
|
||||
|
Loading…
Reference in New Issue
Block a user