Quick Little Powershell Script

Here’s a quick little powershell script I wrote to illustrate the relationship between Aggregates, Shelves, and raid-groups for a student who was a little confused as to their relationship:

$raidGroup = 0;
$shelf=1;
$rgSize=8;
$shelfBays = 24
$numShelves = 2
$totalDisks = ($numShelves * $shelfBays)

write-output("Aggregate Start");
for ( $i = 0 ; $i -lt $totalDisks ; $i++) { 

    $shelfMody = $i % $shelfBays ; 
    $mody = $i % $rgSize ;
    if ( 0 -eq $shelfMody ) {
        Write-Output("------------SHELF------------");
        }
    if ( 0 -eq $mody ) {
        Write-Output("RaidGroup: $raidGroup");
        $raidGroup++;
        $Parity = 2 ; 
    }
    if ( $Parity -eq 2 ) {
        Write-Output("    Parity Disk #1: $i");
        $Parity--;
        } elseif ( $Parity -eq 1 ) {
        Write-Output("    Parity Disk #2: $i");
        $Parity--;
        } else {
        Write-Output("    data Disk: $i");
        }
    }

You can see some of the output below:

Aggregate Start
------------SHELF------------
RaidGroup: 0
    Parity Disk #1: 0
    Parity Disk #2: 1
    data Disk: 2
    data Disk: 3
    data Disk: 4
    data Disk: 5
    data Disk: 6
    data Disk: 7
RaidGroup: 1
    Parity Disk #1: 8
    Parity Disk #2: 9
    data Disk: 10
    data Disk: 11
    data Disk: 12
    data Disk: 13
    data Disk: 14
    data Disk: 15
RaidGroup: 2
    Parity Disk #1: 16
    Parity Disk #2: 17
    data Disk: 18
    data Disk: 19
    data Disk: 20
    data Disk: 21
    data Disk: 22
    data Disk: 23
------------SHELF------------
RaidGroup: 3
    Parity Disk #1: 24
    Parity Disk #2: 25
    data Disk: 26
    data Disk: 27
    data Disk: 28
    data Disk: 29
    data Disk: 30
    data Disk: 31
RaidGroup: 4
    Parity Disk #1: 32
    Parity Disk #2: 33
    data Disk: 34
    data Disk: 35
    data Disk: 36
    data Disk: 37
    data Disk: 38
    data Disk: 39
RaidGroup: 5
    Parity Disk #1: 40
    Parity Disk #2: 41
    data Disk: 42
    data Disk: 43
    data Disk: 44
    data Disk: 45
    data Disk: 46
    data Disk: 47
Posted in netapp, programming, tech | Tagged , , | Leave a comment

Giving away my minolta maxxum 400si

I’m giving away my old minolta 400si to a photography student after years of it sitting in the closet collecting dust. It took me a full two or three months to save up for this thing in ’01, back when I was broke as hell. I’m glad someone’s going to be using it, but I’ve got a feeling it’s going to sting a little bit when they come to actually pick it up.

Posted in Life | Tagged , , | Leave a comment

Ripping my dvd collection

So a while back we had a smallish earth quake, which made my shelves, which were none-to-sturdy anyway, decide the walls were no longer where they wanted to be. I came home to dvds strewn across the floor, and more-or-less, that’s where they’ve stayed ever since (in a slightly neater form, anyway).

About a month or so ago, I decided I would digitize my movie collection, and throw them on one of my home servers. Yes, I have multiple. Yes, there is something wrong with me. Anyway, after finding xbmc works fantastically out of the box on ubuntu, and uses upnp to advertize media to my xbox, it was a no-brainer. The only problem is it takes sooooooooo long to rip a dvd. I’m getting to the point where I might just bittorrent them because it’s faster than ripping the ones I already own. I wonder what the legality of that is.

Posted in Uncategorized | Tagged , , , , , , , , | Leave a comment

Hacked. :/

My hosted web-server got hacked last night. I’m guessing it was via dokuwiki, which was out of date, but dang it, that’s annoying. Never-the-less, tip of the hat to Hidden Pain. Egg on my face.

For the next couple days, I’m going to be replacing the current site, made up of custom-written code, some of which dates back to 1997, with a wordpress blog which will be a bit easier to maintain. Apologies for any broken links or inconvenience.

-Nick

Posted in Uncategorized | Tagged , , , , | Leave a comment

More airline strangeness

Me: hi, I was wondering if any upgrades are available, and if so, how much they cost.

Gate agent: oh, next time just have them put you on the list when you check your bag.

Me: oh, I’m a united frequent flyer, not air Canada. I don’t think I can.

Gate agent: oh, sorry, then we can’t put you on the upgrade list.

Me: I actually don’t want to use miles, or standby. I’d like to see how much it would cost.

Gate agent: I’m sorry sir, we can’t do that with united miles.

Me: I want to pay cash. Do you take cash?

Gate agent: no. We don’t take cash.

Wft? I just tried to give a company money and they refused to take it. Is there a more fundamental principal of business? If a customer wants to buy something, and you can provide it, sell it to them.

Posted in Uncategorized | Leave a comment

Netapp Instructor Wanted

Hi all,

I just wanted to let you know that there is an open position for a Netapp Instructor. You should have extensive real-world netapp experience, be personable, funny, able to tell stories and explain complex subjects in a simple manner. People who have worked as PSEs are probably a good fit. The salary is very competitive, but the main benefits are in the flexibility and schedule. You’ll get to travel (I’ve been to places like hong kong on the company dime) and meet lots of people. I generally only work about two weeks / month, but some some instructors work every week. We will happily teach you how to teach, but just to be up-front, the process of becoming an instructor isn’t instant. You’ll have to take each of the course three times (one to audit, one to co-teach, and one supervised-solo), and you’ll have to do this for the fundamentals class, the san, nfs, cifs, data protection and boot camp classes – it can take a while. Once you’re through that however, I can personally attest to the fact that it’s an *amazing* job.

You would be reporting to me, and I’m a pretty darn good boss. 🙂 Well, I am if you like my management style, anyway. Basically all I want is regular reports on how things are going, what help (if any) you need to do your job better, and then I leave you the heck alone. One of the main benefits of this job is you are your own boss, effectively sub-contracting, and we just make sure you’ve got everything you need, make sure your reviews are consistently good, and you’re getting exposed to the new stuff coming down the pipe. There will also be great opportunities to get exposed to all sorts of other technologies too – cisco, vmware, ubuntu linux – it’s really fun to be able to audit a whole range of different courses, and then bring that back to your netapp classes.

If you’re interested, please email me your resume, or a link to it – any standard format is fine. For bonus points, pretend you’re talking to an eight year old, and explain why the sky is blue. Feel free to look it up, but the actual answer should be yours.

Kindest Regards,
Nick Bernstein, Director of Netapp training, ICM
[si-contact-form form=’1′]
Posted in Uncategorized | Tagged , , , , , , , , | Leave a comment

How changing my homepage let me loose forty pounds and start a company.

Almost two years ago, I decided I was going to sit down and make some changes to my life. I had just finished a four year stint at microsoft, felt burnt out on tech, gotten out of shape due to working regular sixty hour weeks in front of a computer and smoking like a chimney. I sat down and thought about what it was that I wanted to achieve and came up with a list of stuff that I wanted to do. I decided to focus on accomplishing three -smoking, weight loss, and starting a company. I did several things to accomplish these goals, but one of the best, and easiest, was just changing my home page.
Nowadays, when I open up my browser in the morning, I’m greated with three pages. They are as follows: (my company) entrenza.com’s beta page, gmail, and foremost – a google docs spreadsheet entitled yyyy-mm goals and actions. The beta page is related to one of these goals, but lets talk about the spreadsheet. It’s really simple and looks something like this:


Monday Tuesday Wednesday Thursday Friday Saturday Sunday
Goal 1 action another action
Goal 2 action another action
Goal 3 action action

It’s been a pretty successful system. I don’t worry about huge strides, I just worry about accomplishing, one thing towards each goal each day. So far, ‘ve registered a LLC and and have regularly worked part time on a startup for over a year. We’re right about to go into beta. As for getting in shape, when I left seattle two years ago and got my California license, it listed my weight at 205lbs. I renewed last week and had 185lbs on it. Prior to leaving Seattle, you could add another 20 lbs to that. I no longer smoke.

I don’t know if this will be useful to anyone else, but I’ve had some success with it, and who knows, maybe it will work for you. If you try it out, I’d love to hear from you and see how it goes.

Posted in entrenza, Life, tech | Tagged , , , , | Leave a comment

More Human than Human

I’ve been working on a startup project on the side for almost a year now – focusing on pattern recognition, natural language processing stuff, and predictive statistical modeling… it’s been fun. At the core, we’ve put together a language analysis engine which looks at a chunk of text and figures out if it’s positive or negative. In researching this as a problem, we’ve determined that if you take three individuals, and then have them categorize the same random text (blog, article, website, tweet, etc) they will agree 63% of the time. There’s a little bit of variance depending on what’s shown, but plus or minus a couple percentage points, is about how accurate a human is. We’ve gone through several different models in doing the predictions, and tweaked the algorithm quite a bit over multiple different versions, but we recently hit a pretty major milestone – we’re now rating articles, or our engine is, with a 70+% accuracy rate. In other words, if we rate something as positive (meaning the author felt positive about whatever they were writing) 70% of the time, the human will agree with how we rated it. ^_^

We’re better at determining human opinion than the average human is.

We’re going to be going into beta soon, on a service that will allow you to track how positive or negative your brand is, by tracking the mentions on the internet – effectively doing sentiment analysis and tracking; if you’re interested, you can sign up here. You can read more about the project in general at www.entrenza.com.

Thanks to Steve & Jesse & Ben, my co-collaborators on the project for making this happen!

Posted in entrenza, startup, tech | Tagged , , , , | Leave a comment

Would you participate in this kind of contest?

I’m thinking, along w/ some people I’m working on a start-up with, of running a contest to help up “train” the back end “artificial intelligence engine” which is used in our software.

Here’s the gist: you would log-in to a website, and be presented w/ an “article” – this would be a blog, website, etc. you would then rate it as positive, negative, & so forth. Anyone who rated 1000 articles in a month (each takes about 1-2 seconds) would be eligible to win a prize, which would either be an xbox 360, or a playstation 3.

So: Three questions:

  • Would you do something like this?
  • Would you be more inclined to do it for an xbox or a ps3
  • If you would not be inclined, what could we change to make you more inclined to do it?

    Thanks so much!

  • Posted in entrenza, startup, tech | Tagged , , , , , , | 2 Comments

    Making me reach a bit

    I wrote a little while back about some of the things my startup has gotten me to work on, but it occurred to me today, after I being grumpy and frustrated for a good chunk of the day – the firewall died (hardware), the parser’s got a memory leak and is crashing the parse server – about how working on this project has made me a better programmer, technologist, and possibly even a better person.

    Tomorrow, after going out to brunch with some friends, and then cleaning the apartment, I’m going to come back and start doing some code profiling to look for memory leaks. I’ve done standard debugging stuff before, and learned the basics of code optimization and such in school back in the day, but the fact of the matter is, until I started working on the startup project, I mainly wrote smaller programs – utility scripts, small apps, stuff like that. I didn’t really ever get into situations where I had to think about memory leaks, or applications which would basically run constantly. It’s other stuff too – if you write a script to automate the creation of this or that, or a .net app to generate foundry server iron configs, you don’t need to put it in an architectural perspective. Now I have to think about that kind of stuff all the time. “what happens when this breaks?” – “How can I write this so I can add another server and scale out horizontally?” – I actually think about this kind of stuff when I’m coding now. I’ll scratch whole bits of things that worked because they’ll cause grief down the line.

    I think it’s also made me more disciplined. There’s a big difference between doing your job because you know, eventually, if you slack, you’re going to get grief about it, and if you do it well you’ll get rewarded for it – all by someone else, and setting goals and following through on your own. My home page, over the years has been slashdot, popurls, rootprompt.org and a miriad of other websites… this would be on my work browser. Now, it’s (thank you firefox and chrome for having multiple tabs) a google doc spreadsheet of my goals and columns representing dates and actions. Each day I list what I did to achieve those goals. Another tab contains our ticketing system. Another tab contains our intranet site, in which there are a bunch of daily actions that I try to go through. I would never have approached a job like this if I were being paid by someone else. It took doing this on myself to realize the type of mindset and tools I would have to give myself to accomplish these things.

    Another thing that I think has made me a better person is our twice weekly conference call – we have a very loose structure for the company – there’s no office, and we use email, ticketing, IM to communicate and conf. calls to go over progress and complete goals. We basically cover what we’ve done, and what’s next. It also is a good opportunity for me to talk on the phone with friends, who all, at this point, live in different parts of the world. Yes, it’s about a shared goal, and a project, but it’s also about keeping in touch with friends, and doing so regularly. I have traditionally been terrible at keeping in touch with people, and I think that this help me in that regard.

    Tomorrow is going to be frustrating as hell. Don’t get me wrong, I’ll have a nice lunch, and put the work out of my mind during that part, and I’ll enjoy the call – tomorrow’s sunday, one of the days we do it – but when I start getting into phase II of the code profiling stuff, and looking for circular references and objects that aren’t being collected, I’m going to get seriously frustrated and stressed out. I’m going to hate it. But I’ll make strides towards getting it fixed. And the idea that taking on a project of this scope, and how hard it is, is making me a better coder will give me some solace. The idea that I’ve had to change my thinking in regards to where it fits in the architecture, I think has made me a better technologist, and the discipline and keeping in touch with friends has made me a better person, I hope. Yes, I’ll definitely be incredibly frustrated when half the stuff I’m trying to do ends up breaking things temporarily, but I think, in the end, it’ll be worth it.

    Posted in Uncategorized | Tagged , , , , | Leave a comment