Visio Drawing – Server Rack

Background Knowledge


I was given an assignment to virtual layout our entire network server rack and equipment within the serve room. As well I had to make note of where each end of each network cable ended up at with the exception of cables going to the patch box.

I used Microsoft Visio to create the drawing. In many cases I ended up having to create my own stencils from images. Not exactly perfect but it did the job. In those case where I made my own stencil I just use Adobe Photoshop to touch up some free photos of a particular product and then inserted the image into my Visio drawing.

Resources Used for Visio Stencils, Icons and Add-Ins


How To – Setup Sendmail for Masquerading and as a SMTP Smart Host

Background Knowledge


I have multiple OpenBSD web servers some internal and some public (accessible via the Internet) that uses Sendmail. However on the network there is only one publicly known email server. Therefore I require to Sendmail to function as follows, route all email through an SMTP smart host and when routing mail to the SMTP smart host change the email address hostname (masquerade). For example an email sender of “root@foobar.example.com” would be changed to “root@example.com”.

I’m by no means a Sendmail expert, the steps I explain here is what I’ve learned on my own and with the assistance of Zerberus in IRC Freenode #sendmail channel.

Solution


Alter Sendmail’s configuration file adding the following lines. Refer to Sendmail Configuration Readme for further explanation and How To – Setup Sendmail as a Smart_Host for details on how this process is achieved.

FEATURE(genericstable)dnl
FEATURE(generics_entire_domain)dnl
GENERICS_DOMAIN(`example.com')dnl
MASQUERADE_AS(`example.com')dnl
FEATURE(masquerade_envelope)dnl
FEATURE(masquerade_entire_domain)dnl
MASQUERADE_DOMAIN(`foobar.example.com')dnl
define(`SMART_HOST',`[10.10.15.1]')dnl

You will also need to edit Sendmail’s genericstable as follows. On OpenBSD this is located under “/var/mail/genericstable”.

@foobar.example.com  %1@example.com

Example Configuration File (mc)


divert(-1)
#
# Copyright (c) 1998 Sendmail, Inc.  All rights reserved.
# Copyright (c) 1983 Eric P. Allman.  All rights reserved.
# Copyright (c) 1988, 1993
#       The Regents of the University of California.  All rights reserved.
#
# By using this file, you agree to the terms and conditions set
# forth in the LICENSE file which can be found at the top level of
# the sendmail distribution.
#
#

#
#  This configuration only runs sendmail on the localhost interface.
#  This allows mail on the local host to work without accepting
#  connections from the net at large.
#

divert(0)dnl
include(`/usr/share/sendmail/m4/cf.m4')dnl
VERSIONID(`@(#)openbsd-localhost-smarthost.mc $Revision: 1.4 $')
OSTYPE(openbsd)dnl
FEATURE(nouucp, `reject')dnl
FEATURE(`accept_unresolvable_domains')dnl
FEATURE(`no_default_msa')dnl
FEATURE(genericstable)dnl
FEATURE(generics_entire_domain)dnl
GENERICS_DOMAIN(`example.com')dnl
MASQUERADE_AS(`example.com')dnl
FEATURE(masquerade_envelope)dnl
FEATURE(masquerade_entire_domain)dnl
MASQUERADE_DOMAIN(`foobar.example.com')dnl
define(`SMART_HOST',`[10.10.15.1]')dnl
DAEMON_OPTIONS(`Family=inet, address=127.0.0.1, Name=MTA')dnl
DAEMON_OPTIONS(`Family=inet6, address=::1, Name=MTA6, M=O')dnl
DAEMON_OPTIONS(`Family=inet, address=127.0.0.1, Port=587, Name=MSA, M=E')dnl
DAEMON_OPTIONS(`Family=inet6, address=::1, Port=587, Name=MSA6, M=O, M=E')dnl
CLIENT_OPTIONS(`Family=inet6, Address=::')dnl
CLIENT_OPTIONS(`Family=inet, Address=0.0.0.0')dnl
dnl
dnl Some broken nameservers will return SERVFAIL (a temporary failure)
dnl on T_AAAA (IPv6) lookups.
define(`confBIND_OPTS', `WorkAroundBrokenAAAA')dnl
MAILER(local)dnl
MAILER(smtp)dnl

Source: How To – Setup Sendmail as a Smart_Host
Source: Sendmail – Masquerading and Relaying
Source: Sendmail Configuration Readme

How To – Add a Radio Station to MPlayer CE

Background Knowledge


This how to will explain how to add a radio station to the MPlayer CE application, a Wii Homebrew Channel application.

Note: How to edit the MPlayer_CE configuration files is not covered in this how to.
Note: MPlayer_CE supports the following streaming protocols, HTTP/FTP, RTP/RTSP, MMS/MMST, MPST and SDP.

Solution


  1. Edit the “menu.conf” file located under /apps/mplayer_ce/ on the memory card using your favorite text editor such as Notepad, Metapad, Notepad++, etc.
  2. Browse the contents of the “menu.conf” until you find the following cmdlist radio tag below.
    1
    2
    3
    
    <cmdlist name="radio" title="Radio" ptr="<>" >
    <e name="../" ok="menu cancel"/>
    </cmdlist>

    We will be adding a new line after the second line shown above and within the cmdlist tag.

  3. Add a new line (radio station) in between the opening tag and closing tag like so.
    1
    
    <e name="OldSchoolFM" ok="loadlist 'http://78.129.250.9/castcontrol/playlist.php?id=104'"/>

    Replace “OldSchoolFM” with the radio station name and then replace “http://78.129.250.9/castcontrol/playlist.php?id=104″ with the radio station stream feed.

  4. Save the file and now test radio station you just added on the Nintendo Wii.

If the radio station does not play go back and ensure you have the correct station stream feed link. If indeed you have the correct stream feed link then it’s possible it is not accessible in the manner you are trying to access it or the protocol for the station is not support by MPlayer_CE.

Example


1
2
3
4
5
6
7
8
9
10
11
12
<cmdlist name="radio" title="Radio" ptr="<>" >
          <e name="../" ok="menu cancel"/>
	  <e name="OldSchoolFM" ok="loadlist 'http://centova2.cpcustomer.com/tunein.php/janpolet/playlist.pls'"/>
	  <e name="CBC Radio 1" ok="loadlist 'http://radiostreams.cbc.ca/cbc-cbcr1reg-96.m3u'"/>
	  <e name="CBC Radio 2" ok="loadlist 'http://radiostreams.cbc.ca/cbc-cbcr2wpg-128.m3u'"/>
	  <e name="CBC Radio 3 (rock)" ok="loadlist 'http://webradio.cbcradio3.com/rock.m3u'"/>
	  <e name="CBC Radio 3 (electronica)" ok="loadlist 'http://webradio.cbcradio3.com/electronic.m3u'"/>
	  <e name="CBC Radio 3 (Pop)" ok="loadlist 'http://webradio.cbcradio3.com/pop.m3u'"/>
	  <e name="1.FM - Blues" ok="loadlist 'http://blues.1.fm/energyblues128k'"/>
	  <e name=".977 The 80s Channel" ok="loadlist 'http://scfire-ntc-aa01.stream.aol.com:80/stream/1040'"/>
	  <e name="Big R Radio - 80s Metal FM" ok="loadlist 'http://livestream2.bigrradio.com/80sMetalFM'"/>
</cmdlist>

This how to is a tribute to OldSchoolFM, “Let’s Make it Personal!” A dream, a vision, a quality radio station that never got a fair chance.

Mary Had a Little Lamb – Lord’s Prayer

This is a powerful poem and one I felt that should be shared.

I tried to track down the author of this poem but I was unable to determine who the author was. However there is some claim a little girl wrote this poem. If anyone can prove the author or further history please contact me.

Source: Mary had a little lamb


Mary had a little lamb,
His fleece was white as snow.
And everywhere that Mary went,
The Lamb was sure to go.

He followed her to school each day,
T’wasn’t even in the rule.
It made the children laugh and play,
To have a Lamb at school.

And then the rules all changed one day,
Illegal it became;
To bring the Lamb of God to school,
Or even speak His Name!

Every day got worse and worse,
And days turned into years.
Instead of hearing children laugh,
We heard gun shots and tears.

What must we do to stop the crime,
That’s in our schools today?
Let’s let the Lamb come back to school,
And teach our kids to pray!

How To – Resolve Printing an Entire Excel Workbook as one PDF

Background Knowledge


When trying to print an entire Microsoft Excel workbook to a PDF using Adobe PDF or PDF Creator multiple PDFs are created for each worksheet instead of a single PDF file. This is caused by Excel itself on how the worksheets are setup due to one or all of the following settings, print quality, print area and page orientation for each worksheet.

Applies to:

  • Microsoft Excel 2007
  • Microsoft Excel 2003
  • Microsoft Excel 2002
  • Microsoft Excel 2000

Solution


  1. Set “Print Area” for each sheet under “Page Layout/Page Setup”.
  2. Set the “page orientation” under “Page Layout/Page Setup” to portrait or landscape for each sheet as necessary.
  3. Right click on a worksheet tab at the bottom of the screen and click on “Select All Sheets”.
  4. Now under Page Layout/Page Setup set the paper size and print quality for all sheets.

Source: novaPDF Knowledge Base: Printing an entire Excel workbook to a single PDF file
Source: doPDF Forum: Trouble with Multiple Pdfs with one workbook