Page MenuHomePhabricator
Paste P5452

Hardcoded "eth0" across the puppet tree
ActivePublic

Authored by faidon on May 16 2017, 5:13 PM.
Tags
Referenced Files
F8100313: Hardcoded "eth0" across the puppet tree
May 16 2017, 5:13 PM
Subscribers
None
misc:
modules/admin/files/home/rush/.bash_aliases: sudo tcpdump -nn -v -i eth0 -s 1500 -c 1 'ether[20:2] == 0x2000'
modules/admin/files/home/rush/bin/bw.sh: echo e.g. $0 eth0
modules/elasticsearch/manifests/init.pp: $publish_host = '_eth0_',
modules/grafana/files/dashboards/server-board: "text": "eth0",
modules/grafana/files/dashboards/server-board: "value": "eth0",
modules/install_server/files/autoinstall/scripts/early_command.sh:IP=$(ip address show dev eth0 | egrep '^[[:space:]]+inet ' | cut -d ' ' -f 6 | cut -d '/' -f 1)
modules/memcached/files/memkeys-snapshot: /usr/bin/memkeys -i eth0 -R csv -l /dev/null 2>/dev/null | \
modules/monitoring/manifests/host.pp: } elsif $facts['lldppeer_eth0'] {
modules/monitoring/manifests/host.pp: $real_parents = $facts['lldppeer_eth0']
modules/tlsproxy/files/utils/cipher_cap.sh:/usr/sbin/tcpdump -Z $PUSER -npi eth0 --direction=in -s 0 -W 1 -G $SECS -w - "$BPF" 2>/dev/null \
labs/misc:
hieradata/common.yaml: network_public_interface: 'eth0'
hieradata/regex.yaml: network_public_interface: 'eth0'
modules/labs_bootstrapvz/files/firstboot.sh: domain=`grep "option domain-name " /var/lib/dhcp/dhclient.eth0.leases | head -n1 | cut -d \" -f2`
modules/labs_vmbuilder/files/firstboot.sh: domain=`grep "option domain-name " /var/lib/dhcp/dhclient.eth0.leases | head -n1 | cut -d \" -f2`
labs/labstore:
modules/labstore/files/monitor/check_drbd_cluster_ip: If role is primary, check that cluster ip is assigned to the eth0 interface,
modules/labstore/files/monitor/check_drbd_cluster_ip: # eth0 interface
modules/labstore/files/monitor/check_drbd_cluster_ip: ip_assigned = ip in str(subprocess.check_output(['/bin/ip', '-4', 'a', 'list', 'eth0']))
modules/labstore/manifests/monitoring/interfaces.pp: $monitor_iface = 'eth0',
modules/labstore/manifests/traffic_shaping.pp: $eth0_egress = '30000kbps',
modules/labstore/templates/tc-setup.sh.erb:eth0_egress='<%= @eth0_egress %>'
modules/labstore/templates/tc-setup.sh.erb: $TC qdisc del dev eth0 handle ffff: ingress
modules/labstore/templates/tc-setup.sh.erb: $TC qdisc del dev eth0 root
modules/labstore/templates/tc-setup.sh.erb:$TC qdisc add dev eth0 root handle 1: htb default 100
modules/labstore/templates/tc-setup.sh.erb:$TC class add dev eth0 parent 1: classid 1:1 htb rate $nfs_write
modules/labstore/templates/tc-setup.sh.erb:$TC class add dev eth0 parent 1: classid 1:2 htb rate $nfs_write
modules/labstore/templates/tc-setup.sh.erb:$TC class add dev eth0 parent 1: classid 1:3 htb rate $nfs_write
modules/labstore/templates/tc-setup.sh.erb:$TC class add dev eth0 parent 1: classid 1:4 htb rate $nfs_write
modules/labstore/templates/tc-setup.sh.erb:$TC class add dev eth0 parent 1: classid 1:5 htb rate $nfs_write
modules/labstore/templates/tc-setup.sh.erb:$TC class add dev eth0 parent 1: classid 1:100 htb rate $eth0_egress
modules/labstore/templates/tc-setup.sh.erb:$TC filter add dev eth0 parent 1: protocol ip prio 0 u32 \
modules/labstore/templates/tc-setup.sh.erb:$TC filter add dev eth0 parent 1: protocol ip prio 0 u32 \
modules/labstore/templates/tc-setup.sh.erb:$TC filter add dev eth0 parent 1: protocol ip prio 0 u32 \
modules/labstore/templates/tc-setup.sh.erb:$TC filter add dev eth0 parent 1: protocol ip prio 0 u32 \
modules/labstore/templates/tc-setup.sh.erb:$TC filter add dev eth0 parent 1: protocol ip prio 0 u32 \
modules/labstore/templates/tc-setup.sh.erb:$TC qdisc add dev eth0 handle ffff: ingress
modules/labstore/templates/tc-setup.sh.erb:$TC filter add dev eth0 parent ffff: protocol all u32 \
modules/role/manifests/labs/nfs/secondary.pp:class role::labs::nfs::secondary($monitor = 'eth0') {
modules/role/templates/labs/nfs/nfs-manage.sh.erb: /bin/ip address add <%= @cluster_ip %>/24 dev eth0
modules/role/templates/labs/nfs/nfs-manage.sh.erb: -i eth0 <%= @subnet_gateway_ip %> &> /dev/null
modules/role/templates/labs/nfs/nfs-manage.sh.erb: /bin/ip a del <%= @cluster_ip %>/24 dev eth0
cassandra (redundant, ongoing work by Giuseppe will fix these):
hieradata/hosts/aqs1004.yaml: rpc_interface: eth0
hieradata/hosts/aqs1004.yaml: rpc_interface: eth0
hieradata/hosts/aqs1005.yaml: rpc_interface: eth0
hieradata/hosts/aqs1005.yaml: rpc_interface: eth0
hieradata/hosts/aqs1006.yaml: rpc_interface: eth0
hieradata/hosts/aqs1006.yaml: rpc_interface: eth0
hieradata/hosts/aqs1007.yaml: rpc_interface: eth0
hieradata/hosts/aqs1007.yaml: rpc_interface: eth0
hieradata/hosts/aqs1008.yaml: rpc_interface: eth0
hieradata/hosts/aqs1008.yaml: rpc_interface: eth0
hieradata/hosts/aqs1009.yaml: rpc_interface: eth0
hieradata/hosts/aqs1009.yaml: rpc_interface: eth0
lvs (false positive):
manifests/site.pp: # Row A subnets on eth0
manifests/site.pp: interface::tagged { 'eth0.1017':
manifests/site.pp: base_interface => 'eth0',
manifests/site.pp: # Row B subnets on eth0
manifests/site.pp: interface::tagged { 'eth0.1018':
manifests/site.pp: base_interface => 'eth0',
manifests/site.pp: 'eth0': rss_pattern => 'eth0-%d';
manifests/site.pp: # Row A subnets on eth0
manifests/site.pp: interface::tagged { 'eth0.1001':
manifests/site.pp: base_interface => 'eth0',
manifests/site.pp: # Row C subnets on eth0
manifests/site.pp: interface::tagged { 'eth0.1003':
manifests/site.pp: base_interface => 'eth0',
manifests/site.pp: 'eth0': bnx2x => true, txqlen => 10000, rss_pattern => 'eth0-fp-%d';
manifests/site.pp: # Row A subnets on eth0
manifests/site.pp: interface::tagged { 'eth0.2001':
manifests/site.pp: base_interface => 'eth0',
manifests/site.pp: # Row B subnets on eth0
manifests/site.pp: interface::tagged { 'eth0.2002':
manifests/site.pp: base_interface => 'eth0',
manifests/site.pp: 'eth0': bnx2x => true, txqlen => 10000, rss_pattern => 'eth0-fp-%d';
manifests/site.pp: interface::tagged { 'eth0.100':
manifests/site.pp: base_interface => 'eth0',
manifests/site.pp: 'eth0': bnx2x => true, txqlen => 20000, rss_pattern => 'eth0-fp-%d';
manifests/site.pp: 'eth0': bnx2x => true, txqlen => 10000, rss_pattern => 'eth0-fp-%d';
false positives (comments etc.):
modules/cassandra/templates/cassandra.yaml-2.2.erb:# listen_interface: eth0
modules/cassandra/templates/cassandra.yaml-3.7.erb:# listen_interface: eth0
modules/interface/files/interface-rps.py:# The first param is the ethernet interfaces (e.g. 'eth0') and is required.
modules/interface/files/interface-rps.py:# bnx2x this is 'eth0-fp-%d', and for bnx2 and tg3 it is 'eth0-%d'.
modules/interface/files/interface-rps.py:# IRQ based on the supplied device name, e.g. /eth0[^\s0-9]+0$/. If
modules/interface/files/interface-rps.py: """Find RSS IRQs for rx queues matching rss_pattern (e.g. 'eth0-fp-%d')"""
modules/interface/files/interface-rps.py: device = 'eth0'
modules/interface/manifests/rps.pp:# (on bnx2x, this would be "eth0-fp-%d")
modules/interface/manifests/aggregate.pp: # Convert an existing interface, e.g. from eth0 to bond0
modules/ntp/templates/ntp-conf.erb:# complaining that it can't create a IPv6 socket for eth0
modules/stdlib/spec/functions/has_interface_with_spec.rb: :interfaces => 'eth0,lo',
modules/stdlib/spec/functions/has_interface_with_spec.rb: :ipaddress_eth0 => '10.0.0.1',
modules/stdlib/spec/functions/has_interface_with_spec.rb: :muppet_eth0 => 'kermit',
modules/stdlib/spec/functions/has_ip_address_spec.rb: :interfaces => 'eth0,lo',
modules/stdlib/spec/functions/has_ip_address_spec.rb: :ipaddress_eth0 => '10.0.0.1',
modules/stdlib/spec/functions/has_ip_network_spec.rb: :interfaces => 'eth0,lo',
modules/stdlib/spec/functions/has_ip_network_spec.rb: :network_eth0 => '10.0.0.0',