The Multifunctioning DBA


June 29, 2011  7:00 PM

Not Paying For Cable or Satalite



Posted by: Colin Smith
Entertainment, Internet TV

In the recent weeks I have had many people come up to me and ask about how I get TV content without a Cable or Satellite provider. The answer is pretty simple really. I use Over The Air (OTA) for all local content and the internet for the rest. I am sure that there are many ways to do this but I will explain how I do it.

1. I use OTA for all local content. This gets me the big networks like ABC, NBC, CBS, and FOX. to do this you have to have an antenna and some are cheap and work well and some are more expensive and work better in certain areas. You have to research what you need and you can do that at antennaweb.org

2. Windows Media Center – I use Windows Media Center to record all the OTA content that I am interested in. I do this by running Windows 7 Ultimate on a home PC and I have two HD USB Video cards connected to the computer. Windows Media Center will see both video cards and has the ability to record from both simultaneously. this ensures that I do not miss any of the OTA content that I am interested in.  You can set up recordings just like on any DVR and have it grab shows in a series if you like. Here is a link to what I use and I have never had an issue.

Hauppauge 01200 WinTV-HVR-850 USB2.0 Hybrid Video Recorder 1200 (HAUP1200)

Once you have that set up all you need is a device to be able to play that media back on to your TV. I will get into those devices after I cover how I get the internet content.

3. DLNA Server for internet Content- I use a product that I absolutely love called PlayOn. This is a DLNA Server that will run on your computer. I run this on the same computer that I use to record all of my TV. This is a fairly lightweight application that just runs all the time and broadcasts to your network so that any DLNA enabled device can receive the content. They do a good job of adding more “Channels” all the time and they also allow developers to create custom plugins and scripts that will allow for even more content.

4. Home Network – In my house I use all wired connections and everything is connected with a 1G router and Switch. You probably can do 100Mbs and get away with it. Just depends on the quality of the media you are serving up. I like to rip all of my Blue Rays and DVD’s so that I never have to put a disk in to watch them. I can select the movie and it just plays. Since I do Blue Ray I like that I am running on a Gig network. Plenty of internal bandwidth.

5. Devices connected to your TV in order to stream the content. Many devices are available now to be able to do this. In fact some new TVs have this built in and you do not even need another device. I do not have such a TV so I have to utilize other boxes to get the content from my PC to my TV. Here is what I use.

a. XBOX 360 – This device is great. This device is able to play all the media from Play On as it is a DLNA device but it also is MS so it has the ability to become a Media Center Extender. This is very nice because I can not only watch the shows that I have recorded, but I can also watch live TV from here streaming and this allows you to rewind, Pause, and FF. This is also nice because it includes a very nice Guide of what is on and what you have set up to record. You can also set up recordings, remove Recordings, and delete shows that are recorded but you have already wathed. Big bang for the money especially since it is a very nice gaming console.

b. PS3 – This is another great device as it is also a great gaming machine and gives me a lot of the same ability that the XBOX give me. This is also DLNA enabled so I can stream all of the Play On content. This can not be used as a Media Center Extender, but if you enable sharing on your PC in Windows Media Player then the PS3 can stream all of the recorded content. You do not have the ability to see the nice guide, stream live TV, manage recordings, or delete the recordings that you have just watched. Still a great device and this also gives you the added benefit of a BD player and the XBOX does not have that.

c. Wii – This is a great device but not as useful for the media streaming. So the Wii is a fantastic Family oriented gaming device and is a ton of fun for all, but when it comes to media streaming it has some downfalls. First is that it is not HD. The best you will get out of it is 480p video and that is only if you go out and get the connector needed for that resolution output. Second is that it is not natively a DLNA device. The guys over at Play ON have made the Wii work for them though. They have written some custom code that will allow you to open your browser on the Wii and connect to a special site that will find your Play On installation and allow you to play the content. No love for the shows that you have recorded via Media Center though.

d. Blue Ray Players – I have two that work. A Samsung and a Sony. Now both are great players and the Samsung is also a 3D BD Player. Both work great as far as streaming the Play On Content but do not have the ability to play the recorded shows from the Media Center. Video Quality is Amazing using both and I can stream BD Rips to either as well as the PS3. All have the processing power to keep up and both can handle a good amount of video formats.

So that is how I have it set up in my house and I also take advantage of Netflix Streaming as well. All devices are capable of Netflix and most have it built in as an app.  So that is how I live without cable or satallite. you will need a decent internet connection. Mine is 10Mbps down and I think the minimum for PlayOn is 2Mbps. Other than that it is very inexpensive after you have all the hardware that you need. All that being said I will say that I do miss live sports but that is all I miss. Look at what you watch and do the research to see if you can get the content that matters to you online before making this jump.

Good luck and I hope that this will help.

June 29, 2011  6:00 PM

MS Cert Test prices go up on the 1st



Posted by: Colin Smith
Certification, Training

Just a quick reminder that if you want to get an MS Certification you need to get it on the books by the first or you will be paying an additional $25.00 staring on July 1st. So get out there and get it done.

Thanks


June 29, 2011  4:19 PM

Good Baby News



Posted by: Colin Smith
Baby, Personal

Last week my wife went in to have some tests done to find out the odds of the baby having some genetic defects. This was really cool as we got to do a 3d ultrasound and really got to see some cool pictures of the baby. It was really amazing. It is almost like looking at a photo of the baby. Now my baby takes after mommy in the fact that the baby is camera shy. The little bugger kept his or her hands over the face the entire time. But it was still really cool to see. I do not think that we will be doing anymore like that though since we do not want to know the sex of the baby and at this time it was still to early to tell. Anyway, they took a lot of measurements, listened to and looked at the heart beat, that was really cook to hear that, and looked at other areas of blood flow. We also saw that the baby has two hemispheres of the brain, I always say two is better than one. They also took some blood samples and sent all that information off to a lab to have it analyzed. The results are in and it appears, knocking on wood, that the baby is healthy and free of genetic defects, at least those that they can test for. The results showed the odds being like 1 in 3,427 that our baby would have one of these issues. So I hope that the baby is not that one but the odds are in our favor.


June 23, 2011  4:33 PM

AZ POSH



Posted by: Colin Smith
AZ POSH, POSH, Powershell, Training

The Arizona Powershell users group has started posting meeting videos online. this is very cool because I usually do not have the ability to get to the meetings but I would love to see the content. So far the content has been great and I really hope that they can continue to post these for us. Thanks to all involved for making this content accessible for those of us who can’t attend the meetings.

http://www.azposh.com/videos/

The one with Don Jones is especially good. That guy is awesome.

Enjoy


June 23, 2011  8:00 AM

PASS Summit Disappointment



Posted by: Colin Smith
PASS Summit, Speaking, Training

Last week I was notified that my submission to speak at the PASS SUMMIT was not accepted. I am bummed out about it very much. This means that I will not be attending the SUMMIT this year and I really wanted to go. I just can not get work to pay for the SUMMIT and all the travel since I am also going to SQLSkills training in August. Of the two I am very happy to go to the training this year as I think I will get more out of it. That is not to say that the Summit does not have great content and value. It really does. My company just is not going to be able to swing both and I understand that. It is not cheap and I am thankful that they send me to one of the two and hopefully I will be able to attend in 2012. I was really hoping to be able to speak though. I have such a great time doing it at the SQL Saturday events that I have been to and I would love to take it to the next level. I was giving the reason of not enough speaking experience. I can understand that and I hope to attend more SQL Saturday events and hope to come up with another session or two so I can get more experience. Perhaps I will be able to speak in 2012.

All that being said I want to congratulate all who were excepted and let you know I wish I was there to suck in all that knowledge that you are sharing. I hope all that attend have a great time and learn a lot.


June 22, 2011  11:00 PM

Check DB online before running Job



Posted by: Colin Smith
DB Online, T-SQL

I was also asked to make sure that I have jobs set up on my servers that have database mirroring set up. They only want the job to run if the database is online and they do not want to have to enable and disable jobs when failovers occur. So I did the following.


/* Style Definitions */
table.MsoNormalTable
{mso-style-name:”Table Normal”;
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:”";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:”Calibri”,”sans-serif”;
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:”Times New Roman”;
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:”Times New Roman”;
mso-bidi-theme-font:minor-bidi;}

declare @online int

set @online = (select state from sys.databases

where name = ‘Database_name’)

if @online = 1

begin

raiserror (‘Database is not the current principal. not attempting to backup.’, 16,1)

End

else

Print ‘The Database is online’

So you can see that this is also pretty simple. I just check in sys.databases to make sure that the database of interest is online. If not then I have the step fail and I have the job set to quit the job reporting success. That way I do not see a bunch of job failures when it actually did just what I wanted. If the database is online then the step succeeds and moves on to step 2. This way everyone is happy.

hope this helps


June 22, 2011  8:23 PM

Fail over Mirror database with Powershell



Posted by: Colin Smith
DR, Mirror, Mirror Fail over, Powershell

Today I was asked if I could help out by writing a simple script that would fail over a mirrored database from one server to the other and back if and when needed. I thought sure I can. I mean to do the failover with T-SQL is really simple but I can automate it. So here is the T-SQL to fail over.

ALTER DATABASE Your_DBNAME SET PARTNER FAILOVER

Well that is very simple but to automate it will take a bit more work. No problem though. Break out the powershell and away we go.


/* Style Definitions */
table.MsoNormalTable
{mso-style-name:”Table Normal”;
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-qformat:yes;
mso-style-parent:”";
mso-padding-alt:0in 5.4pt 0in 5.4pt;
mso-para-margin:0in;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:”Calibri”,”sans-serif”;
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-fareast-font-family:”Times New Roman”;
mso-fareast-theme-font:minor-fareast;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:”Times New Roman”;
mso-bidi-theme-font:minor-bidi;}

## Step one: Load SMO Assembly

[System.Reflection.Assembly]::LoadWithPartialName(‘Microsoft.SqlServer.SMO’ ) | out-null

#Step Two: Define Variables

$failover = 0

$instances = “workdog”, “workdog\test”

##Step Three: find current database that is the principal

foreach ($instance in $instances)

{

$s = New-Object (‘Microsoft.SqlServer.Management.Smo.Server’ ) $instance

$databases = $s.Databases

#$databases | select name, mirroringstatus, status

foreach($db in $databases)

{

$name = $db.name

$mirrorstatus = $db.MirroringStatus

$mirrorstatus = $mirrorstatus.ToString()

$status = $db.Status

if(($mirrorstatus -ne “None”) -and ($Status -eq “Normal”) -and ($failover -eq 0))

{

echo “$name is on $instance”

$query = “ALTER DATABASE $name SET PARTNER FAILOVER”

$failover = 1

Invoke-Sqlcmd -serverinstance $instance -Database master -Query $query

So basically what I am doing is setting up SMO connections to my instances and looping thru all the databases. If I find a database that is mirrored and the primary then I know what instance to run the SQL Query against and I do. I also set $failover = 1 so that the script knows that if it iterates thru and finds that the second instance now has the primary do not run the failover again.

Hope this helps


June 21, 2011  7:00 PM

Blue Ray Issues



Posted by: Colin Smith
BD, DLNA, Network Devices, WHS

this weekend I went out and I purchased a blue ray player that would go into a room that does not get used much but since I do not have Cable or Satellite, I wanted to be able to watch all my media from my media center and from the web and from my DLNA server in that room. I went and found what looked to be the perfect device.

PanasonicDMP-BD755
On the surface this looks to be a great player at a great price. So I got it home connected to my Gig Switch, HDMi to the TV, and power. Started to walk through the set up and it locks up. Over and over again this happened. I took it back to the store and got a replacement unit and again the same result. This time I got online and found that this unit has a very obscure and specific flaw. I have a WHS on my network and I love it. Well apparently the BD Player does not like it and this is what causes the lock ups. I disconnected my WHS just to test this and now everything works great. So it is a great player if you do not have a WHS on your network. I attempted to upgrade the firmware in hopes that Panasonic had addressed the issue but it had the latest firmware already applied. So back to the drawing board and now off to find another device.


June 21, 2011  3:54 PM

SPIDS disconnecting from DB



Posted by: Colin Smith
Performance, SP, SPIDS drop

Ever run into the following issue?

<Date><Time> <spid> Error: 18056, Severity: 20, State: 29.

I did and it was a mess. Production system just starting dropping spids. It finally stopped with me doing nothing except trying to find out what it was. It took a while but I finally got it figured out. This is a bug in SQL Server 2008 and is patched in SP1 CU14. Here is a link to the article.

http://support.microsoft.com/kb/2543687

I applied SP2 and have not seen the issue since. Hope this will help.


June 1, 2011  7:49 PM

Great Powershell Article



Posted by: Colin Smith
IT Pros, Powershell, Scripting

I found this article today and I thought I should mention it and then post a bit about some of the comments that I see. So go check out the article at Redmondmag.com and also read the comments. Below are my thoughts on some of the comments.

Some of the comments I hear all the time and one of them is just plain wrong.

The comment about Powershell not running in Windows XP is WRONG. Plain and simple. If you say that the only reason you are not learning and using Powershell is because you have Windows XP then you are just making excuses and not even a good one. Powershell absolutely runs on XP and above. With windows XP you have to go and download it. Powershell is not just built in on XP but you can run it. Before you use that as an excuse, go out and make sure it is a valid excuse. That is just lazy and wrong.

The majority of the other comments all have a similar sentiment and I hear the same thing from others that I work with and from IT Pros that I have spoken to at Conferences and other events. Here are some of the things that I hear.

“I am too busy to learn a new Language.”

“I already know Pearl, or some other language that is cross platform, so why should I learn a MS only language?”

“I do not want to waste my time learning Powershell because it will not help with my current projects.”

So in my mind all of these are similar and I can argue with them all. (in most cases)

“I am too busy to learn a new language.”

First, IT is almost organic. It is always changing and we as IT Pros do not have a choice but to change and grow with it if we want to stay valid in our chosen profession. I am not saying that you need to learn everything as that is not possible but you do need to learn and adapt and grow with technology. If you only deal with Unix and or LInuz then you win and you do not need Powershell. If you work with anything in MS Windows though, then you need to learn it. We are all BUSY but Powershell is a tool that can make you much more efficient in your job. You can automate many tasks and even if you do not want to automate, you can still manually perform most tasks with Powershell in one location instead of having to log into 50 servers to get the information that you need and or make the changes you need. Writing one script may save you Hours of work so that can help make you less busy.

“I already know Pearl, or some other language that is cross platform, so why should I learn a MS only language?”

That is great and I understand that these languages are cross platform and how that is very useful, but does pearl (or these other languages) have the ability to interface with .net and all of the other powershell supported MS applications? I think that Powershell is a tool and it is something that any one working in a windows world with MS applications would be happy to have.

“I do not want to waste my time learning Powershell because it will not help with my current projects.”

If your current Project is on Windows and or using MS applications then I do not buy that for an instant. I think that Powershell can help with any project that is using MS software. Even if it is something simple like checking disk space. This is just a lazy excuse and the real answer should be that you just do not care or that you are too lazy to learn it.

So that is my two cents. I think if you are a admin or IT Pro that works with MS software you are falling behind the curve if you are not learning powershell.


Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to: