Part II: Apple iPads, Apple TVs, Bonjour & AirPlay Across Subnets Using Open-Source Software

In my previous post HERE, I gave a brief description of Apple's implementation of the mDNS protocol which they named "Bonjour". I explained why the protocol does not function in a segmented (subnetted) network and described the open-source solution that we deploy for our clients which is comprised of a free, open-source Gentoo Linux (virtual) server running the open-source implementation of the mDNS protocol called "Avahi."

My goal in this post is to describe in detail exactly how to implement your very own virtual "Bonjour Gateway" in a VMware vSphere environment.



Basic Information

The virtual Bonjour Gateway server in this howto will be aptly named "Avahi." Named of course after the open-source service daemon we will be using to re-broadcast Bonjour (mDNS) traffic across subnets.

As explained in my previous blog post, the mDSN protocol is not a routed protocol so this virtual server must be directly connected to each of the VLANS (subnets) that Bonjour traffic needs to be forwarded from or onto.

In this howto, we will set up a simple, L3 routed demonstration network with a total of five VLANs/subnets. The VLANs and subnets will be defined as follows:

VLAN     Subnet         Subnet Description
------------------------------------------
  5      10.5.0.0/24    Servers Subnet
 10      10.10.0.0/24   AppleTV 1 (Wired)
 20      10.20.0.0/24   AppleTV 2 (Wired)
100      10.100.0.0/24  Student Wireless
101      10.101.0.0/24  Adults Wireless



The demonstration network will also have the following devices defined and they will be interconnected as shown in Figure 1 below.

  • One core router or L3 switch - We will use a Dell 6624
  • One L2 switch - We will use a Dell 5548P
  • One (physical) VMware ESXi host server with a minimum of four ethernet interfaces
  • One (virtual) Linux server connected to several VLANS and running the Avahi service
  • Three other (virtual) example servers for network completeness
  • One wireless access point
  • One wireless Student laptop
  • One wireless Adult tablet
  • Two AppleTVs, each one on a different (wired) subnet

FIGURE 1:





Configure The Switches

The L3 switch we have available for our demonstration network is a Dell 6224 L3 switch. The syntax for other switches will be different of course, but the concept and configuration requirements are the same.



Dell 6224 L3 Switch
We will configure the Dell 6224 L3 switch as follows:

  • IP routing enabled so that the switch will route IP traffic between subnets
  • Five VLANs (5, 10, 20, 100, 101), each with an IP address that will be used as the default gateway address for devices on that subnet
  • A 3Gbps Link Aggregate Group (LAGG), configured in TRUNK mode, connected to our VMware ESXi host server. This LAGG will have all five VLANs tagged on it
  • A 1Gbps link configured in TRUNK mode, with VLANs 10, 20, 100, 101 tagged on it. This link will be connected to a Dell 5548P L2 switch

Log into the 6224 switch via ssh, telnet, or serial port. Enable ip routing and then create and configure the VLANs.

User:admin
Password:thisIsNotThePassword

revpol6224 > en

revpol6224 # configure

revpol6224 (config)# ip routing

revpol6224 (config)# vlan database 

revpol6224 (config-vlan)# vlan 5,10,20,100,101
Warning: The use of large numbers of VLANs or interfaces may cause significant
delays in applying the configuration.

revpol6224 (config-vlan)# exit

revpol6224 (config)# interface vlan 5

revpol6224 (config-if-vlan50)# name "Servers VLAN"

revpol6224 (config-if-vlan50)# ip address 10.5.0.254 /24

revpol6224 (config-if-vlan50)# exit

revpol6224 (config)# interface vlan 10

revpol6224 (config-if-vlan10)# name "AppleTV 1 VLAN"

revpol6224 (config-if-vlan10)# ip address 10.10.0.254 /24

revpol6224 (config-if-vlan10)# exit

revpol6224 (config)# interface vlan 20

revpol6224 (config-if-vlan20)# name "AppleTV 2 VLAN"

revpol6224 (config-if-vlan20)# ip address 10.20.0.254 /24

revpol6224 (config-if-vlan20)# exit

revpol6224 (config)# interface vlan 100

revpol6224 (config-if-vlan100)# name "Student Wireless VLAN"

revpol6224 (config-if-vlan100)# ip address 10.100.0.254 /24

revpol6224 (config-if-vlan100)# exit

revpol6224 (config)# interface vlan 101

revpol6224 (config-if-vlan101)# name "Adults Wireless VLAN"

revpol6224 (config-if-vlan101)# ip address 10.101.0.254 /24

revpol6224 (config-if-vlan101)# exit



Create the 3Gbps LAGG which will consist of ports 1-3 on the Dell 6624 L3 switch. Set it to TRUNK mode and then add all the necessary VLANs to the newly defined LAGG. GENERAL mode is usually a better option and allows for more flexibility, but for this demonstration TRUNK mode will work just fine.

This 3Gbps LAGG will be used to connect our VMware ESXi host server to the network, and will provide 3Gbps of shared bandwidth for all of the virtual machines on the VMware ESXi host server. Of course you probably would never connect any servers directly to your core router, but remember this is just a demonstration network. :)

revpol6224 (config)# interface range ethernet 1/g1-1/g3

revpol6224 (config-if)# description "Member of 3Gbps CH1 to VMware ESXi Host"

revpol6224 (config-if)# channel-group 1 mode on

revpol6224 (config-if)# exit

revpol6224 (config)# interface port-channel 1

revpol6224 (config-if-ch1)# description "3Gbps LAGG to VMware ESXi Host"

revpol6224 (config-if-ch1)# switchport mode trunk

revpol6224 (config-if-ch1)# switchport trunk allowed vlan add 5,10,20,100,101

revpol6224 (config-if-ch1)# exit



Configure gigabit ethernet port 4 (1/g4) on the 6224 switch as a tagged trunk port to our 5548P L2 switch, and add the required VLANs to the trunk:

revpol6224 (config)# interface ethernet 1/g4

revpol6224 (config-if)# description "Tagged trunk to 5548P L2 switch"

revpol6224 (config-if)# switchport mode trunk

revpol6224 (config-if)# switchport trunk allowed vlan add 10,20,100,101

revpol6224 (config-if)# exit



Save the current running configuration to the startup configuration so the changes stay after a reboot:

revpol6224 (config)# exit

revpol6224 # copy running-config startup-config

revpol6224 # exit

revpol6224 > 



Dell 5548P L2 Switch

Now configure our 5548P L2 switch as follows:

  • port 1 - Tagged trunk connected to 6224 L3 switch with VLANs 10, 20, 100, 101
  • port 2 - Tagged trunk connected to wireless access point with VLANs 100, 101
  • port 3 - Access port on VLAN 10 (AppleTV 1)
  • port 4 - Access port on VLAN 20 (AppleTV 2)

Create and name the VLANs on the 5548P L2 switch:

User Name:admin
Password:thisIsAlsoNotThePassword

revpol5548P > en

revpol5548P # configure

revpol5548P (config-vlan)# vlan database

revpol5548P (config-vlan)# vlan 10,20,100,101

revpol5548P (config-vlan)# exit

revpol5548P (config)# interface vlan 10

revpol5548P (config-if)# name "AppleTV 1 VLAN"

revpol5548P (config-if)# exit

revpol5548P (config)# interface vlan 20

revpol5548P (config-if)# name "AppleTV 2 VLAN"

revpol5548P (config-if)# exit

revpol5548P (config)# interface vlan 100

revpol5548P (config-if)# name "Student Wireless VLAN"

revpol5548P (config-if)# exit

revpol5548P (config-if)# interface vlan 101

revpol5548P (config-if)# name "Adults Wirelsss VLAN"

revpol5548P (config-if)# exit



Configure the tagged trunk on port 1 (gigabitethernet 1/0/1) of the 5548P, and add the required VLANs to it. This is the uplink to the Dell 6224 L3 switch:

revpol5548P (config)# interface gigabitethernet 1/0/1

revpol5548P (config-if)# description "Tagged trunk to 6224 L3 switch"

revpol5548P (config-if)# switchport mode trunk

revpol5548P (config-if)# switchport trunk allowed vlan add 10,20,100,101

revpol5548P (config-if)# exit



Configure the tagged trunk on port 2 (gigabitethernet 1/0/2) of the 5548P and add the required VLANs (100, 101) to it. This will be the connection to the access point:

revpol5548P (config)# interface gigabitethernet 1/0/2

revpol5548P (config-if)# description "Tagged trunk to access point"

revpol5548P (config-if)# switchport mode trunk

revpol5548P (config-if)# switchport trunk allowed vlan add 100,101

revpol5548P (config-if)# exit



Configure the two access ports on VLAN 10 and VLAN 20 for the two wired AppleTVs. Clearly, these two subnets will have more than one AppleTV on them. The diagram shows one AppleTV per port for simplicity.

revpol5548P (config)# interface gigabitethernet 1/0/3

revpol5548P (config-if)# description "AppleTV 1 network"

revpol5548P (config-if)# switchport mode access

revpol5548P (config-if)# switchport access vlan 10

revpol5548P (config-if)# exit

revpol5548P (config)# interface gigabitethernet 1/0/4

revpol5548P (config-if)# description "AppleTV 2 network"

revpol5548P (config-if)# switchport mode access

revpol5548P (config-if)# switchport access vlan 20

revpol5548P (config-if)# exit



Save the current running configuration to the startup configuration so the changes stay after a reboot:

revpol5548P (config)# exit

revpol5548P # copy running-config startup-config

revpol5548P # exit

revpol5548P > 

** NOTE ** After configuring your switches you should always copy the startup-configuration to a server via tftp so that you have backup copies.





VMware ESXi Host Server Network Configuraton

In the "Basic Information" section of this howto above, the VMware ESXi host server was defined as follows: "One (physical) VMware ESXi host server with a minimum of four ethernet interfaces."

Open the VMware vSphere client, and connect to your server.

In FIGURE 2 below, there is one ESXi host server "vm.revpol.com" with several virtual machines configured on it. The Configuration tab is displayed, and "Networking" has been selected in the Hardware box.

Virtual switch "vSwitch0" is connected to the first ethernet interface (vmnic0), and only has a "VMkernel port" defined on it. This ethernet interface (vmnic0) and vSwitch pair is reserved ONLY for management traffic to/from the ESXi host itself. No additional Ports, nor Port Groups will be configured on vSwitch0 and no virtual machines will ever be conected to vSwitch0. This type of configuration will guarantee that traffic to/from your virtual machines will never be in contention with the management traffic to/from the ESXi host server.

The next three ethernet interfaces (vmnic1 - vmnic3) will be bonded together in a LAGG and connected to the core switch. This will provide the virtual servers with a shared bandwidth of 3Gbps to the network.

FIGURE 2:

To get started with the 3Gbps LAGG, click the "Add Networking" link in the top right corner.

You will be presented with the following dialog box:

FIGURE 3:

Choose "Virtual Machine" and click "Next."

FIGURE 4:

Select the "Create a virtual switch" radio button, and check the boxes next to vmnic1, vmnic2, and vmnic3.

Click "Next."

FIGURE 5:

Change the Network Label to "ALL VLANS", and choose "All (4095)" from the VLAN ID dropdown selector.

Click "Next."

FIGURE 6:

The Summary dialog box shows that a "Virtual Machine Port Group" using three ethernet interfaces in a 3Gbps LAGG, has been created and it has ALL VLANS tagged on it.

Click "Finish" and you will be returned to the Networking Configuration page of the ESXi host server, and your new vSwitch1 will be displayed under the Management vSwitch0.

FIGURE 7:






Create A New Virtual Linux Server


In the vSphere client, click File --> New --> Virtual Machine (or just click CTRL-N).

FIGURE 8:


FIGURE 9:

There will not be anything very special about the Linux Avahi server, so just select "Typical."

Click Next.

FIGURE 10:

Give the new machine a sensible name. "Avahi" seems reasonable.

Click Next.

FIGURE 11:

Select a datastore where your virtual machine will be stored. This demonstration server has ony one datastore named "datastore1", so that is the one we will choose.

Click Next.

FIGURE 12:

VMware has support for several guest Operating Systems, including of course several distributions of Linux.

Click the Linux radio button, and then click the "Version" dropdown. In this list, choose the distribution closest to the one you will be installing. We will be installing a Gentoo Linux distribution, which is not "specifically" supported by name, so we will choose "Other Linux (64-bit).

Click Next.

FIGURE 13:

Our Gentoo Linux Avahi server will not require very much disk space, but the default of 8GB is certainly too small. Change this to at least 20GB.

Check the "Allocate and commit space on demand (Thin Provisioning)" check box. This will keep the new server's disk utilization on the datastore to only what it uses, and will therefore keep the virtual machine smaller and easier to manipulate in the future (e.g.: clone, create template, vStorage Motion, etc)

Click Next.

FIGURE 14:

The new virtual server is just about ready to be created on the datastore.

Make sure to check the "Edit the virtual machine settings before completion" check box.

Click Continue.

FIGURE 15:

FIGURE 15 above shows the default settings for the new virtual machine.

We need to make a few modifications before we are ready to save and then power up the virtual machine.

FIGURE 15a:

There is no reason to have a floppy drive in our virtual machine.

In the left pane, select "New Floppy (adding)"

Click the "Remove" button.

FIGURE 16:

In the left pane, select the "New NIC (adding)"

Then, on the right side under "Network Connection", click the "Network Label" dropdown and choose the "ALL VLANS" network that we created previously.


FIGURE 17:

In the left pane, select "New CD/DVD (adding)"

Then, on the right side, under "Device Status", check the box "Connect at power on"

Under "Device Type" click the "Datastore ISO File", then click "Browse."

Browse to the Linux installation CD/DVD ISO file that you uploaded to the datastore previously.

Click "OK"

Now click "Finish"

Your virtual machine is now ready to be powered on.




Start Up New Linux Server And Install The Operating System

Right click on the new "Avahi" virtual server in the list of virtual servers and click "Open Console."

Next, click the green (power-on / play) arrow button and your new virtual machine will boot from the ISO previously selected.


FIGURE 18:

At this point, the new virtual Linux server has been booted with the Gentoo Linux minimal install CD and is in LIVE CD mode. It is ready to have the Gentoo Linux distribution installed to its hard drive. The next step is to follow the Gentoo Linux Installation Guide HERE.

Remember to add 802.1q (VLAN) support when configuring your kernel. :)

If you have chosen a Linux distribution other than Gentoo, follow the appropriate installation instructions, then return here to the next step: Configuring The Network Interfaces



*NOTE* Since this is a headless Gentoo Linux server, there is no reason to install any graphical X Window support. Be sure edit the /etc/portage/make.conf file and add "-X -gnome -kde" to the USE environment variable like so:

/etc/portage/make.conf:

USE="-X -gnome -kde bindist mmx sse sse2"





Configuring The Network Interfaces

I will attempt to show how to configure the network interfaces for several different distributions of Linux, If I miss a distribution that you feel is important, please let me know and I will try to include that as well.

First we need to make sure that the iproute2, and vconfig packages are installed. These two packages will provide 802.1q (VLAN) support on our network interface.

Gentoo:

# emerge vconfig iproute2



On other distributions these packages may already be installed. If not, you will need to install them:

Red Hat / CentOS:

# yum install iproute
# yum install vconfig

Ubuntu / Debian:

# apt-get install iproute
# apt-get install vlan



Next, edit the network configuration file and set it up as follows:

Gentoo:
/etc/conf.d/net

# waa - 20130917
#   5 - Servers
#  10 - AppleTV 1 (Wired)
#  20 - AppleTV 1 (Wired)
# 100 - Students Wireless
# 101 - Adults Wireless
# -----------------------

# Define the VLANS that will be used
# ----------------------------------
vlans_eth0="5 10 20 100 101"

# Define the naming convention for the VLAN interfaces
# ----------------------------------------------------
vlan5_name="vlan5"
vlan10_name="vlan10"
vlan20_name="vlan20"
vlan100_name="vlan100"
vlan101_name="vlan101"

# Bind IP addresses to the interfaces
# -----------------------------------
#
# All VLANs are tagged, set no IPv4 address 
# on the primary ethernet interface
# -----------------------------------------
config_eth0="null"            
config_vlan5="10.5.0.4/24"
config_vlan10="10.10.0.4/24"
config_vlan20="10.20.0.4/24"
config_vlan100="10.100.0.4/24"
config_vlan101="10.101.0.4/24"

# Configure the default route using the gateway on the Servers VLAN
# -----------------------------------------------------------------
routes_vlan5="default via 10.5.0.254"

In other distributions, each VLAN interface requires a separate configuration file which makes it more difficult to demonstrate in-line. For now, these two are currently placeholders for separate documentation pages to come:

Red Hat / CentOS
Debian / Ubuntu



We need to tell the server to start our network interfaces and make sure they also start up at boot time:

Gentoo:

# cd /etc/init.d
# ln -s net.lo net.eth0
# rc-update add net.eth0 default
# rc-service net.eth0 start



On the other Linux distributions, the network interfaces are configured to start at boot by default. There is no need to manually set them up here. We should be able to just restart them:

Red Hat / CentOS:

# service network restart

Ubuntu / Debian:

# service networking restart



Verify that the interfaces are properly configured by running the ifconfig command. The output should look similar to the following:

All Distributions:

# ifconfig

eth0: flags=4163  mtu 1500
        ether 00:50:56:bd:00:03  txqueuelen 1000  (Ethernet)   <--- Notice there is no IPv4
        RX packets 11084383  bytes 1932472483 (1.7 GiB)             address bound to this interface
        RX errors 0  dropped 19368  overruns 0  frame 0
        TX packets 9535939  bytes 4788165488 (4.4 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        loop  txqueuelen 0  (Local Loopback)
        RX packets 333  bytes 151661 (148.1 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 333  bytes 151661 (148.1 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

vlan5: flags=4163  mtu 1500
        inet 10.5.0.4  netmask 255.255.255.0  broadcast 10.5.0.255
        ether 00:50:56:bd:00:03  txqueuelen 0  (Ethernet)
        RX packets 1473436  bytes 401316807 (382.7 MiB)
        RX errors 0  dropped 19226  overruns 0  frame 0
        TX packets 2692643  bytes 1371192454 (1.2 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

vlan10: flags=4163  mtu 1500
        inet 10.10.0.4  netmask 255.255.255.0  broadcast 10.10.0.255
        ether 00:50:56:bd:00:03  txqueuelen 0  (Ethernet)
        RX packets 36993  bytes 3485440 (3.3 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 2009044  bytes 891429875 (850.1 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

vlan20: flags=4163  mtu 1500
        inet 10.20.0.4  netmask 255.255.255.0  broadcast 10.20.0.255
        ether 00:50:56:bd:00:03  txqueuelen 0  (Ethernet)
        RX packets 722403  bytes 109542756 (104.4 MiB)
        RX errors 0  dropped 29  overruns 0  frame 0
        TX packets 1966289  bytes 880751727 (839.9 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

vlan100: flags=4163  mtu 1500
        inet 10.100.0.4  netmask 255.255.255.0  broadcast 10.100.0.255
        ether 00:50:56:bd:00:03  txqueuelen 0  (Ethernet)
        RX packets 183165  bytes 12743965 (12.1 MiB)
        RX errors 0  dropped 6  overruns 0  frame 0
        TX packets 66  bytes 4605 (4.4 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

vlan101: flags=4163  mtu 1500
        inet 10.101.0.4  netmask 255.255.255.0  broadcast 10.101.0.255
        ether 00:50:56:bd:00:03  txqueuelen 0  (Ethernet)
        RX packets 4964095  bytes 757037361 (721.9 MiB)
        RX errors 0  dropped 595  overruns 0  frame 0
        TX packets 1048591  bytes 561754230 (535.7 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0





Install And Configure The Avahi Service

Run the following two commands.

Gentoo:

# echo "net-dns/avahi -gdbm -introspection" >> /etc/portage/package.use
# emerge avahi

The first command tells portage (Gentoo's package management system) to build avahi without support for gdbm and introspection. These two features are not required and would cause portage to pull in several more uncessary packages when building avhai.

The second command tells portage to download, compile, and install the avahi service.



Red Hat / CentOS:

# yum install avahi

Debian / Ubuntu:

# apt-get install avahi-daemon



Edit the avahi configuration file and make the following changes:

All Distributions
/etc/avahi/avahi-daemon.conf


...the rest of this config file should be left unchanged...

allow-interfaces=vlan10,vlan20,vlan100,vlan101
# Notice that vlan5 is not included. In this demonstration, there is no
# reason to listen for, nor re-broadcast mDNS traffic onto the Servers
# subnet because there will never be an Apple mobile device, nor an AppleTV
# on the Servers subnet

enable-reflector=yes
# This line is the key. It tells the avahi-daemon process to listen for
# mDNS traffic on all of the allowed-interfaces defined above and then 
# re-broadcast any mDNS traffic that it hears onto all of the other 
# allowed interfaces



Start the avahi-daemon service and configure it to start on boot:

Gentoo

# rc-service avahi-daemon start
# rc-update add avahi-daemon default

Red Hat / CentOS:

# service avahi-daemon start
# chkconfig --add avahi-daemon

Ubuntu / Debian:

# service avahi-daemon start
# update-rc.d avahi-daemon defaults





Test

At this point you are ready to test the configuration!

Connect your AppleTV to your wired network, and an iPad or other device to your wireless network.

Follow the proper AirPlay setup steps for your verion of iOS HERE.



Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

CentOS 6

I wanted to show my thanks for this post by giving you my steps in setting up centos 6. Feel free to add/delete/modify whatever you want.

Comparison to Gentoo: Initial installation of the OS is MUCH easier. Setting up the vlans involves 3 files per vlan. So I suppose it's a tossup as far as time. My vlan11 is servers, 10 is workstations, 50 is wifi. For now I'm just joining workstations to wifi

Get the centos installer (I used current which is 6.5)
https://www.centos.org/
##make a vm with dvd1 mounted at startup
##choose minimal install (this is different than using the minimal iso as that doesn't even have cron
##reboot and login as root
##Ensure that the module is loaded by entering the following command:
lsmod | grep 8021q
#If the module is not loaded, load it with the following command:
modprobe 8021q
vi /etc/sysconfig/network-scripts/ifcfg-eth0
##press i for insert mode. esc to exit insert mode.
##make it like this
DEVICE=eth0
TYPE=Ethernet
ONBOOT=yes
#NM_CONTROLLED=yes
BOOTPROTO=none
HWADDR=yourMacGoesHere
:x to save and exit
vi /etc/sysconfig/network-scripts/ifcfg-vlan11
VLAN=yes
VLAN_NAME_TYPE=VLAN_PLUS_VID_NO_PAD
DEVICE=vlan11
PHYSDEV=eth0
BOOTPROTO=dhcp
ONBOOT=yes
TYPE=Ethernet
USERCTL=no

##repeat for vlan10, vlan50
##then you have to add a route and rule or cenos tries to send traffic from one vlan out the wrong vlan
##this is what I followed:
##http://commandline.ninja/2013/01/14/centos-policy-routing-why-yes-it-can-be-done/
vi /etc/iproute2/rt_tables
#add the following lines
11 vlan11
50 vlan50
10 vlan10

#then add /etc/sysconfig/network-scripts/route-vlan11 with:
default table vlan11 via 10.99.11.1
#then add /etc/sysconfig/network-scripts/rule-vlan11 with:
from 10.99.11.173 table vlan11
#repeat for other vlans
#so with 1 network adapter and 3 vlans I have 10 files. lame
#maybe someone can figure out a cleaner way to do this, but my way works!

##continue on to my normal centos setup notes:
#Allow root ssh so you can get out of the stupid vmconsole
vi /etc/ssh/sshd_config
#uncomment the
PermitRootLogin yes

#iptables and SElinux are on. You may need to turn these off.
service iptables stop
#DISABLE SELINUX THE BITCH
vi /etc/sysconfig/selinux

//more good stuff before moving on to app installation///
//get the epel repo up
cd ~
wget http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noa...
rpm -ivh epel-release-6-8.noarch.rpm
#get git for scripts, zip and unzip are handy too
sudo yum install git zip unzip

/////////VMWARE Tools install////////////////
su root
yum install gcc kernel-devel perl make openssh-clients wget
//Mount the VMWare Tools ISO in the gui
mkdir /mnt/cdrom
mount /dev/cdrom /mnt/cdrom
cp /mnt/cdrom/VMwareTools*.gz /tmp
cd /tmp
tar -C /tmp -zxvf VMwareTools*.gz
cd vmware-tools-distrib
./vmware-install.pl
//accept the defaults
//then run the config thing
umount /mnt/cdrom

/////////avahi install///////
#basically I followed your simple steps, only thing was I got a dbus error when starting until I figured out I had to start the messagebus service:

yum install avahi
/etc/avahi/avahi-daemon.conf
allow-interfaces=vlan10,vlan20,vlan100,vlan101
enable-reflector=yes

service messagebus start
service avahi-daemon start
chkconfig --add messagebus
chkconfig --add avahi-daemon

Thanks for the feedback

I approved your post because you obviously put some thought into it and I am sure it will help a CentOS user from the future. :)

I would argue though, that leaving "PermitRootLogins = yes" is a no-no, and would recommend that you instead create a user while logged in via the VMware console, and then ssh in as that user. I would also recommend allowing ssh logins via public key only.

Also, I rarely actually have to install Gentoo these days. I keep a "Gentoo64bitTemplate" (mostly) up to date on each of our clients' VMware systems, so deploying a new Gentoo Linux server is a couple clicks, and then a name-changing script away.

And one helpful hint: To su to root and inherit all of root's environment just do:

$ su -

Or if you feel that must enter an account name:

$ su - root

also works.

Cheers!

--
Bill

Post new comment

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <b> <i> <u> <strong> <cite> <code> <pre> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
z
B
$
?
{
v
Enter the code without spaces and pay attention to upper/lower case.